3v4l.org

run code in 200+ php & hhvm versions
Bugs & Features
<?php const x = array('a' => 'b'); var_dump($x['a']);
based on nGNd9
Output for 5.6.0 - 5.6.30, 7.0.0 - 7.3.0rc3
Notice: Undefined variable: x in /in/vXX7v on line 4 NULL
Output for hhvm-3.15.4
Warning: Constants may only evaluate to scalar values in /in/vXX7v on line 3 Notice: Undefined variable: x in /in/vXX7v on line 4 NULL