3v4l.org

run code in 200+ php & hhvm versions
Bugs & Features
<?php $foo = [ "int" => function($a, $b, $c) { var_dump($a, $b, $c); } ]; $foo[int](1,2,3);
Output for 7.2.6
Warning: Use of undefined constant int - assumed 'int' (this will throw an Error in a future version of PHP) in /in/qdn2r on line 9 int(1) int(2) int(3)
Output for 5.4.10 - 7.1.20
Notice: Use of undefined constant int - assumed 'int' in /in/qdn2r on line 9 int(1) int(2) int(3)
Output for 5.3.20 - 5.3.29
Parse error: syntax error, unexpected '[' in /in/qdn2r on line 3
Process exited with code 255.