3v4l.org

run code in 300+ PHP versions simultaneously
<?php function create_reflection($function){ if (is_array($function)) { return new \ReflectionMethod($function[0], $function[1]); } if (is_object($function) && !$function instanceof \Closure) { return new \ReflectionMethod($function, '__invoke'); } return new \ReflectionFunction($function);} $r = create_reflection('Exception::getMessage'); var_dump(get_class($r));
Output for git.master, git.master_jit, rfc.property-hooks
Fatal error: Uncaught ReflectionException: Function Exception::getMessage() does not exist in /in/tjR7R:3 Stack trace: #0 /in/tjR7R(3): ReflectionFunction->__construct('Exception::getM...') #1 /in/tjR7R(5): create_reflection('Exception::getM...') #2 {main} thrown in /in/tjR7R on line 3
Process exited with code 255.

This tab shows result from various feature-branches currently under review by the php developers. Contact me to have additional branches featured.

Active branches

Archived branches

Once feature-branches are merged or declined, they are no longer available. Their functionality (when merged) can be viewed from the main output page


preferences:
49.85 ms | 401 KiB | 8 Q