3v4l.org

run code in 200+ php & hhvm versions
Bugs & Features
<?php $foo = []; define('SOME_CONSTANT', 'bar'); $foo⦋SOME_CONSTANT⦌ = 123; var_dump($foo[SOME_CONSTANT]);
based on F1eBK
Output for 5.6.0 - 5.6.30, hhvm-3.15.4, 7.0.0 - 7.2.0
Notice: Undefined index: bar in /in/KZqC3 on line 5 NULL