3v4l.org

run code in 300+ PHP versions simultaneously
<?php class CSqlException extends Exception { public function __construct($p_Message, $p_Code=0) { parent::__construct($p_Message, $p_Code, null); } } try { throw new CsqlException('foo', "abc"); } catch (Exception $e) { echo $e->getMessage(); }
Output for git.master, git.master_jit, rfc.property-hooks
Fatal error: Uncaught TypeError: Exception::__construct(): Argument #2 ($code) must be of type int, string given in /in/0gviC:8 Stack trace: #0 /in/0gviC(8): Exception->__construct('foo', 'abc', NULL) #1 /in/0gviC(13): CSqlException->__construct('foo', 'abc') #2 {main} thrown in /in/0gviC 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:
49.58 ms | 401 KiB | 8 Q