Bug #73927 [NEW]: phpdbg fails with windows error prompt at "watch array"
| From: | stahlstift at gmail dot com | Date: | Fri, 13 Jan 2017 14:28:04 +0000 |
| Subject: | Bug #73927 [NEW]: phpdbg fails with windows error prompt at "watch array" | ||
| Groups: | php.bugs | ||
| Request: | Send a blank email to php-bugs+get-206599@lists.php.net to get a copy of this message | ||
From: stahlstift at gmail dot com
Operating system: Windows 10 Pro
PHP version: 7.0.14
Package: phpdbg
Bug Type: Bug
Bug description:phpdbg fails with windows error prompt at "watch array"
Description:
------------
C:\Users\username\PhpstormProjects\phpdbg>phpdbg
[Welcome to phpdbg, the interactive PHP debugger, v0.5.0]
To get help using phpdbg type "help" and press enter
[Please report bugs to <http://bugs.php.net/report.php>]
prompt> e test.php
[Set execution context:
C:\Users\username\PhpstormProjects\phpdbg\test.php]
[Successful compilation of
C:\Users\username\PhpstormProjects\phpdbg\test.php]
prompt> l 20
00001: <?php
00002:
00003: // Generate some mock data
00004: $example = [1, 23, 23423, 256436, 3463, 4363, 457];
00005: foreach (range(1, 1000) as $val) {
00006: $example[] = mt_rand(1, 10000);
00007: }
00008:
00009: // Stuff to debug
00010: function doCoolStuff($value)
00011: {
00012: $value++;
00013:
00014: return mt_rand(1, 1000);
00015: }
00016:
00017: $lower = [];
00018: foreach ($example as $key => $value) {
00019: if ($value < 100) {
00020: $lower[] = $value;
prompt> b 19
[Breakpoint #0 added at
C:\Users\username\PhpstormProjects\phpdbg\test.php:19]
prompt> r
[Breakpoint #0 at C:\Users\username\PhpstormProjects\phpdbg\test.php:19,
hits: 1]
>00019: if ($value < 100) {
00020: $lower[] = $value;
00021: } else {
prompt> c
[Breakpoint #0 at C:\Users\username\PhpstormProjects\phpdbg\test.php:19,
hits: 2]
>00019: if ($value < 100) {
00020: $lower[] = $value;
00021: } else {
prompt> w $value
[Set watchpoint on $value]
prompt> w $lower[]
Test script:
---------------
<?php
// Generate some mock data
$example = [1, 23, 23423, 256436, 3463, 4363, 457];
foreach (range(1, 1000) as $val) {
$example[] = mt_rand(1, 10000);
}
// Stuff to debug
function doCoolStuff($value)
{
$value++;
return mt_rand(1, 1000);
}
$lower = [];
foreach ($example as $key => $value) {
if ($value < 100) {
$lower[] = $value;
} else {
doCoolStuff($value);
}
}
--
Edit bug report at https://bugs.php.net/bug.php?id=73927&edit=1
--
Try a snapshot (PHP 5.4): https://bugs.php.net/fix.php?id=73927&r=trysnapshot54
Try a snapshot (PHP 5.5): https://bugs.php.net/fix.php?id=73927&r=trysnapshot55
Try a snapshot (trunk): https://bugs.php.net/fix.php?id=73927&r=trysnapshottrunk
Fixed in SVN: https://bugs.php.net/fix.php?id=73927&r=fixed
Fixed in release: https://bugs.php.net/fix.php?id=73927&r=alreadyfixed
Need backtrace: https://bugs.php.net/fix.php?id=73927&r=needtrace
Need Reproduce Script: https://bugs.php.net/fix.php?id=73927&r=needscript
Try newer version: https://bugs.php.net/fix.php?id=73927&r=oldversion
Not developer issue: https://bugs.php.net/fix.php?id=73927&r=support
Expected behavior: https://bugs.php.net/fix.php?id=73927&r=notwrong
Not enough info: https://bugs.php.net/fix.php?id=73927&r=notenoughinfo
Submitted twice: https://bugs.php.net/fix.php?id=73927&r=submittedtwice
register_globals: https://bugs.php.net/fix.php?id=73927&r=globals
PHP 4 support discontinued: https://bugs.php.net/fix.php?id=73927&r=php4
Daylight Savings: https://bugs.php.net/fix.php?id=73927&r=dst
IIS Stability: https://bugs.php.net/fix.php?id=73927&r=isapi
Install GNU Sed: https://bugs.php.net/fix.php?id=73927&r=gnused
Floating point limitations: https://bugs.php.net/fix.php?id=73927&r=float
No Zend Extensions: https://bugs.php.net/fix.php?id=73927&r=nozend
MySQL Configuration Error: https://bugs.php.net/fix.php?id=73927&r=mysqlcfg