3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<?php const x = ['a' => 'b'];
based on GHli3
Output for 5.6.8 - 5.6.28, 7.0.0 - 7.1.0
Output for hhvm-3.10.0 - 3.12.0
Warning: Constants may only evaluate to scalar values in /in/qUCSJ on line 3
Output for 5.4.0 - 5.5.35
Fatal error: Arrays are not allowed as constants in /in/qUCSJ on line 3
Process exited with code 255.