3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<?php $arraykey[] = new stdClass; $arraykey->date = "2008-05-20"; $arraykey->page_views = 1; $arraykey->date = "2011-08-03"; $arraykey->page_views = 2; $arraykey->date = "2008-08-20"; $arraykey->page_views = 3; $arraykey->date = "2008-08-27"; $arraykey->page_views = 2; $arraykey->date = "2011-10-11"; $arraykey->page_views = 3; var_dump($arraykey);
Output for 5.0.0 - 5.6.28, 7.0.0 - 7.1.0
Warning: Attempt to assign property of non-object in /in/AdidM on line 4 Warning: Attempt to assign property of non-object in /in/AdidM on line 5 Warning: Attempt to assign property of non-object in /in/AdidM on line 6 Warning: Attempt to assign property of non-object in /in/AdidM on line 7 Warning: Attempt to assign property of non-object in /in/AdidM on line 8 Warning: Attempt to assign property of non-object in /in/AdidM on line 9 Warning: Attempt to assign property of non-object in /in/AdidM on line 10 Warning: Attempt to assign property of non-object in /in/AdidM on line 11 Warning: Attempt to assign property of non-object in /in/AdidM on line 12 Warning: Attempt to assign property of non-object in /in/AdidM on line 13 array(1) { [0]=> object(stdClass)#1 (0) { } }
Output for hhvm-3.10.0 - 3.12.0
Warning: Cannot access property on non-object in /in/AdidM on line 4 Warning: Cannot access property on non-object in /in/AdidM on line 5 Warning: Cannot access property on non-object in /in/AdidM on line 6 Warning: Cannot access property on non-object in /in/AdidM on line 7 Warning: Cannot access property on non-object in /in/AdidM on line 8 Warning: Cannot access property on non-object in /in/AdidM on line 9 Warning: Cannot access property on non-object in /in/AdidM on line 10 Warning: Cannot access property on non-object in /in/AdidM on line 11 Warning: Cannot access property on non-object in /in/AdidM on line 12 Warning: Cannot access property on non-object in /in/AdidM on line 13 array(1) { [0]=> object(stdClass)#1 (0) { } }
Output for 4.3.0 - 4.4.9
array(1) { [0]=> object(stdClass)(0) { } }