3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<?php class D { public $first = 'test'; public $second = 12; public $third = false; public $forth = '0xa'; public $fifth = null; } $o = new D(); var_dump((array) $o);
Output for 5.3.6 - 5.6.28, hhvm-3.10.0 - 3.12.0, 7.0.0 - 7.1.0
array(5) { ["first"]=> string(4) "test" ["second"]=> int(12) ["third"]=> bool(false) ["forth"]=> string(3) "0xa" ["fifth"]=> NULL }