3v4l.org

run code in 300+ PHP versions simultaneously
<?php function stuff(int $i, string $s, float $f, Point $p, int $m = 0) {} try { str_replace(1); } catch(ArgumentCountError $e) { echo $e->getMessage(), PHP_EOL; } try { stuff(1); } catch(ArgumentCountError $e) { echo $e->getMessage(), PHP_EOL; }
Output for git.master, git.master_jit
str_replace() expects at least 3 arguments, 1 given Too few arguments to function stuff(), 1 passed in /in/3G8EO on line 11 and at least 4 expected

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:
46.17 ms | 405 KiB | 5 Q