3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<?php $func = create_function('', 'return 123;'); $ref = new ReflectionFunction($func); $closure = $ref->getClosure(); $func(); $closure();
Output for 5.4.0 - 5.6.21, 7.0.0 - 7.1.0
Output for hhvm-3.10.0 - 3.12.0
Fatal error: (1) call the function without enough arguments OR (2) Unable to find function "" OR (3) function was not in invoke table OR (4) function was renamed to something else.
Process exited with code 255.
Output for 5.0.0 - 5.3.29
Fatal error: Call to undefined method ReflectionFunction::getClosure() in /in/runjL on line 5
Process exited with code 255.
Output for 4.3.2 - 4.4.9
Fatal error: Cannot instantiate non-existent class: reflectionfunction in /in/runjL on line 4
Process exited with code 255.
Output for 4.3.0 - 4.3.1
Fatal error: Cannot instantiate non-existent class: reflectionfunction in /in/runjL on line 4