3v4l.org

run code in 500+ PHP versions simultaneously
<?php function foo(&$obj) { return $obj; } $o = array(); // No errors foo($o); call_user_func('foo', $o); call_user_func('foo', [$o]); $a[] = array(); $a[] = array(); $a[] = array(); // Warning: Parameter 1 to foo() expected to be a reference, value given in call_user_func('foo', array_slice($a, 0, 1));
Output for rfc.property-hooks, git.master, git.master_jit
Warning: foo(): Argument #1 ($obj) must be passed by reference, value given in /in/TZaVe on line 10 Warning: foo(): Argument #1 ($obj) must be passed by reference, value given in /in/TZaVe on line 11 Warning: foo(): Argument #1 ($obj) must be passed by reference, value given in /in/TZaVe on line 18

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:
39.66 ms | 2044 KiB | 4 Q