3v4l.org

run code in 300+ PHP versions simultaneously
<?php $generator = function () { try { try { echo "generator\n"; yield; echo "after yield\n"; } finally { echo "finally\n"; throw new Exception('test'); } } catch (Throwable $exception) { echo "finally exception caught\n"; } echo "end of generator should not be reached\n"; }; echo "create\n"; $generator = $generator(); echo "iterate\n"; $generator->current(); echo "unset\n"; unset($generator); echo "done";
Output for rfc.property-hooks, git.master, git.master_jit
create iterate generator unset finally finally exception caught end of generator should not be reached done

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:
99.54 ms | 2698 KiB | 4 Q