MantisBT - Xdebug
View Issue Details
0001048Xdebug(No Category)public2014-04-14 15:222014-05-20 01:00
SvetlanaZem 
derick 
normalmajoralways
closedfixed 
2.2.1 
2.2.6 
5.4.10-5.4.14
0001048: Can not get $GLOBAL variable by property_value on function context
While debugging code:
<?php

function foo() {
    $GLOBALS['CACHE'] = str_pad('', 1024, 'l') . 'k';
    xdebug_break(); // 1
    echo 1;
}

foo();
xdebug_break(); // 2
echo 1;

property_value -n $GLOBAL['CACHE'] is available only in global context (xdebug_break(); // 2). The command will be responced by "can not get property" if it was called from function (xdebug_break(); // 1).

Log file is attached.
No tags attached.
log global_value_xdebug.log (43,619) 2014-04-14 15:22
https://bugs.xdebug.org/file_download.php?file_id=216&type=bug
Issue History
2014-04-14 15:22SvetlanaZemNew Issue
2014-04-14 15:22SvetlanaZemFile Added: global_value_xdebug.log
2014-05-19 13:07derickNote Added: 0002812
2014-05-19 13:07derickAssigned To => derick
2014-05-19 13:07derickStatusnew => acknowledged
2014-05-20 01:00derickStatusacknowledged => closed
2014-05-20 01:00derickResolutionopen => fixed
2014-05-20 01:00derickFixed in Version => 2.2.6
2016-07-31 13:35derickCategoryDebug client (console) => debugclient (debugging tool)
2016-07-31 13:35derickCategorydebugclient (debugging tool) => (No Category)

Notes
(0002812)
derick   
2014-05-19 13:07   
There is indeed a bug, or rather, something that is not implemented. The property_value implementation misses support for -c, so it doesn't use the superglobals context. This should be an easy fix though.