3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<?php function print_name($first, $middle, $last) { echo $last . ', ' . $first . ' ' . $middle; } print_name(...'joe');
based on lI6XW
Output for 7.1.0
Warning: Only arrays and Traversables can be unpacked in /in/6Pc7C on line 6 Fatal error: Uncaught ArgumentCountError: Too few arguments to function print_name(), 0 passed in /in/6Pc7C on line 6 and exactly 3 expected in /in/6Pc7C:2 Stack trace: #0 /in/6Pc7C(6): print_name() #1 {main} thrown in /in/6Pc7C on line 2
Process exited with code 255.
Output for 5.6.8 - 5.6.28, 7.0.0 - 7.0.14
Warning: Only arrays and Traversables can be unpacked in /in/6Pc7C on line 6 Warning: Missing argument 1 for print_name(), called in /in/6Pc7C on line 6 and defined in /in/6Pc7C on line 2 Warning: Missing argument 2 for print_name(), called in /in/6Pc7C on line 6 and defined in /in/6Pc7C on line 2 Warning: Missing argument 3 for print_name(), called in /in/6Pc7C on line 6 and defined in /in/6Pc7C on line 2 Notice: Undefined variable: last in /in/6Pc7C on line 3 Notice: Undefined variable: first in /in/6Pc7C on line 3 Notice: Undefined variable: middle in /in/6Pc7C on line 3 ,
Output for hhvm-3.12.0
Warning: Only containers may be unpacked in /in/6Pc7C on line 6 Warning: print_name() expects exactly 3 parameters, 0 given in /in/6Pc7C on line 3 Notice: Undefined variable: last in /in/6Pc7C on line 3 Notice: Undefined variable: first in /in/6Pc7C on line 3 Notice: Undefined variable: middle in /in/6Pc7C on line 3 ,
Output for hhvm-3.10.0

Process exited with code 153.
Output for 5.5.24 - 5.5.35
Parse error: syntax error, unexpected '.' in /in/6Pc7C on line 6
Process exited with code 255.
Output for 4.4.2 - 4.4.9, 5.1.0 - 5.4.45
Parse error: syntax error, unexpected '.', expecting ')' in /in/6Pc7C on line 6
Process exited with code 255.
Output for 4.3.0 - 4.3.1, 4.3.5 - 4.4.1, 5.0.0 - 5.0.5
Parse error: parse error, unexpected '.', expecting ')' in /in/6Pc7C on line 6
Process exited with code 255.
Output for 4.3.2 - 4.3.4
Parse error: parse error, expecting `')'' in /in/6Pc7C on line 6
Process exited with code 255.