3v4l.org

run code in 200+ php & hhvm versions
Bugs & Features
<?php class A { public $b = [][]; }; $a = new A;
Output for 7.0.0
Fatal error: Cannot use [] for reading in /in/cg1F3 on line 4
Process exited with code 255.
Output for 5.6.8 - 5.6.16
Parse error: syntax error, unexpected ']' in /in/cg1F3 on line 4
Process exited with code 255.
Output for 5.4.9 - 5.5.30
Parse error: syntax error, unexpected '[', expecting ',' or ';' in /in/cg1F3 on line 4
Process exited with code 255.
Output for 5.3.19 - 5.3.29
Parse error: syntax error, unexpected '[' in /in/cg1F3 on line 4
Process exited with code 255.