3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<?php $hello = "hello"; foreach($hello[] as $test) { echo $test; }
based on TdGri
Output for 5.2.3 - 5.4.31
Fatal error: Cannot use [] for reading in /in/HOO1P on line 3
Process exited with code 255.
Output for 5.2.1 - 5.2.2
Fatal error: Invalid opcode 81/16/8. in /in/HOO1P on line 3
Process exited with code 255.
Output for 4.3.2 - 5.2.0
Fatal error: [] operator not supported for strings in /in/HOO1P on line 3
Process exited with code 255.
Output for 4.3.0 - 4.3.1
Fatal error: [] operator not supported for strings in /in/HOO1P on line 3