ID: 48580 Updated by: j...@php.net -Summary: ArrayObject swallows properties (dump and reflection access) Reported By: t...@php.net -Status: Open +Status: Feedback Bug Type: SPL related Operating System: Gentoo PHP Version: 5.2.9 New Comment:
Still not fixed in 5.2.11..? Can you check and update the version if not.. Previous Comments: ------------------------------------------------------------------------ [2009-06-17 10:06:40] t...@php.net Description: ------------ Attributes defined in classes deriving from ArrayObject do not show up in var_dump() and cannot be accessed via Reflection. Note that this is fixed in 5.3 already. Reproduce code: --------------- class Bar extends ArrayObject { protected $foo = 23; private $bar = 42; } var_dump( new Bar() ); Expected result: ---------------- object(Bar)#1 (0) { ["foo:protected"]=> int(23) ["bar:private"]=> int(42) } Actual result: -------------- object(Bar)#1 (0) { } ------------------------------------------------------------------------ -- Edit this bug report at http://bugs.php.net/?id=48580&edit=1