3v4l.org

run code in 300+ PHP versions simultaneously
<?php class MyException extends Exception { public function __construct($message = "", $code = 0, Throwable $previous = null) { print "2. Exception constructor\n"; parent::__construct($message, $code, $previous); } } function ololo() { try { print "1. Start\n"; throw new MyException("4. Exception message\n"); } finally { return "3. Return statement\n"; } } try { print ololo(); } catch (Exception $e) { print $e->getMessage(); }
Output for git.master, git.master_jit, rfc.property-hooks
1. Start 2. Exception constructor 3. Return statement

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:
62.89 ms | 401 KiB | 8 Q