3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<?php $obj = new ReflectionFunction('phpinfo'); $obj = $obj->getClosure(); serialize($obj);
based on IImEn
Output for 7.0.0 - 7.1.0
Fatal error: Uncaught Exception: Serialization of 'Closure' is not allowed in /in/jRmit:4 Stack trace: #0 /in/jRmit(4): serialize(Object(Closure)) #1 {main} thrown in /in/jRmit on line 4
Process exited with code 255.
Output for hhvm-3.12.0
Warning: Attempted to serialize unserializable builtin class Closure$ReflectionFunction::getClosure;520589053 in /in/jRmit on line 4
Output for hhvm-3.10.0

Process exited with code 153.
Output for 5.4.0 - 5.6.28
Fatal error: Uncaught exception 'Exception' with message 'Serialization of 'Closure' is not allowed' in /in/jRmit:4 Stack trace: #0 /in/jRmit(4): serialize(Object(Closure)) #1 {main} thrown in /in/jRmit on line 4
Process exited with code 255.
Output for 5.0.0 - 5.3.29
Fatal error: Call to undefined method ReflectionFunction::getClosure() in /in/jRmit on line 3
Process exited with code 255.
Output for 4.3.2 - 4.4.9
Fatal error: Cannot instantiate non-existent class: reflectionfunction in /in/jRmit on line 2
Process exited with code 255.
Output for 4.3.0 - 4.3.1
Fatal error: Cannot instantiate non-existent class: reflectionfunction in /in/jRmit on line 2