3v4l.org

run code in 300+ PHP versions simultaneously
<?php class Foo { public function doFoo(int &$e) { try { throw new \Exception(); } catch (\Exception $e) { } } } $foo = new Foo(); $a = 1; $foo->doFoo($a); var_dump($a);
Output for git.master, git.master_jit
object(Exception)#2 (7) { ["message":protected]=> string(0) "" ["string":"Exception":private]=> string(0) "" ["code":protected]=> int(0) ["file":protected]=> string(9) "/in/q4dFb" ["line":protected]=> int(8) ["trace":"Exception":private]=> array(1) { [0]=> array(6) { ["file"]=> string(9) "/in/q4dFb" ["line"]=> int(18) ["function"]=> string(5) "doFoo" ["class"]=> string(3) "Foo" ["type"]=> string(2) "->" ["args"]=> array(1) { [0]=> int(1) } } } ["previous":"Exception":private]=> NULL }

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:
41.11 ms | 511 KiB | 4 Q