3v4l.org

run code in 200+ php & hhvm versions
Bugs & Features
<?php class C { const A = []; }
Output for 5.6.8 - 7.2.0
Output for 5.4.2 - 5.5.35
Fatal error: Arrays are not allowed in class constants in /in/JLD5Q on line 5
Process exited with code 255.
Output for 5.3.18 - 5.3.29
Parse error: syntax error, unexpected '[' in /in/JLD5Q on line 5
Process exited with code 255.