3v4l.org

run code in 200+ php & hhvm versions
Bugs & Features
<?php function fn($arg1, $arg2, array ...$params) { } fn(1,"abc", [3], 4, [5]);
Output for 7.0.0 - 7.2.0
Fatal error: Uncaught TypeError: Argument 4 passed to fn() must be of the type array, integer given, called in /in/JDett on line 4 and defined in /in/JDett:2 Stack trace: #0 /in/JDett(4): fn(1, 'abc', Array, 4, Array) #1 {main} thrown in /in/JDett on line 2
Process exited with code 255.
Output for 5.6.8 - 5.6.28
Catchable fatal error: Argument 4 passed to fn() must be of the type array, integer given, called in /in/JDett on line 4 and defined in /in/JDett on line 2
Process exited with code 255.
Output for 5.4.10 - 5.5.35
Parse error: syntax error, unexpected '.', expecting '&' or variable (T_VARIABLE) in /in/JDett on line 2
Process exited with code 255.
Output for 5.3.20 - 5.3.29
Parse error: syntax error, unexpected '.', expecting '&' or T_VARIABLE in /in/JDett on line 2
Process exited with code 255.