3v4l.org

run code in 300+ PHP versions simultaneously
<?php $generator = function () { try { yield 1; return; } finally { yield 2; echo "Finally.\n"; } }; $generator = $generator(); echo $generator->current() . "\n";
Output for rfc.property-hooks, git.master, git.master_jit
1 Fatal error: Uncaught Error: Cannot yield from finally in a force-closed generator in /in/47AHU:8 Stack trace: #0 [internal function]: {closure}() #1 {main} thrown in /in/47AHU on line 8
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:
59.36 ms | 2136 KiB | 4 Q