3v4l.org

run code in 200+ php & hhvm versions
Bugs & Features
<?php $o = new stdclass(); $o->a = 'hello, world'; $b = ['a'=>'a']; echo $o->$b['a'];
based on 5fG43
Output for 7.0.0 - 7.2.0
Notice: Array to string conversion in /in/8A2eY on line 7 Notice: Undefined property: stdClass::$Array in /in/8A2eY on line 7
Output for 5.4.12 - 5.6.28
hello, world
Output for 5.3.22 - 5.3.29
Parse error: syntax error, unexpected '[' in /in/8A2eY on line 5
Process exited with code 255.