View Issue Details

IDProjectCategoryView StatusLast Update
0000710XdebugStep Debuggingpublic2020-03-12 17:36
Reporteridrozd Assigned Toderick  
PrioritynormalSeverityfeatureReproducibilityhave not tried
Status resolvedResolutionno change required 
Product Version2.1.0 
Summary0000710: Special magic method to specify object's dynamic properties to be dislpayed by debugger
Description

Modern PHP frameworks rely heavily on use of magic methods, __get in particular.
It would be very handy if developer could tell xdebug how to display objects of particular class.

For example, in my Yii application i have ORM model Client, and i need to watch how it's attributes change with every step of code, but since it's dynamic property, calculated by getAttributes method, the only way is to assign watch on it, but it's tedious, and incorrect watch will break programm.

What i propose is to xdebug to scan object's for presense of special ,method ("__xdebug_inspect" for example) and use it to display object in balloon evaluation and "variables" window of IDE. The method should return string or some kind of config in array.

TagsNo tags attached.
Operating System
PHP Version5.3.6

Activities

derick

2014-02-27 19:10

administrator   ~0002685

PHP is getting support for this with __debugInfo in PHP 5.6, so no real need in Xdebug anymore.

Issue History

Date Modified Username Field Change
2011-08-18 06:26 idrozd New Issue
2014-02-27 19:10 derick Note Added: 0002685
2014-02-27 19:10 derick Status new => resolved
2014-02-27 19:10 derick Resolution open => no change required
2014-02-27 19:10 derick Assigned To => derick
2020-03-12 17:36 derick Category Feature/Change request => Step Debugging