3v4l.org

run code in 200+ php & hhvm versions
Bugs & Features
<?php class A { function y() { return (object)array("was"=>'da los')); } function x() { return array("was"=>'da los')); } } $a = new A(); var_dump($a->x()['was'], $a->x()->was);
Output for 7.0.0
Parse error: syntax error, unexpected ')', expecting ';' in /in/kWj0X on line 6
Process exited with code 255.
Output for 5.3.20 - 5.6.16
Parse error: syntax error, unexpected ')' in /in/kWj0X on line 6
Process exited with code 255.