3v4l.org

run code in 300+ PHP versions simultaneously
<?php function takesInt(int $val): int { return $val + 1; } takesInt("not int");
Output for git.master, git.master_jit, rfc.property-hooks
Fatal error: Uncaught TypeError: takesInt(): Argument #1 ($val) must be of type int, string given, called in /in/ib9KV on line 7 and defined in /in/ib9KV:3 Stack trace: #0 /in/ib9KV(7): takesInt('not int') #1 {main} thrown in /in/ib9KV on line 3
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:
48.26 ms | 405 KiB | 5 Q