<?php
function baz(...$param){
var_dump($param);
}
baz(...[0,1,2,3], 4, 5, ...[6,7,8]);
- Output for 5.6.0 - 5.6.21, 7.0.0 - 7.0.6
- Fatal error: Cannot use positional argument after argument unpacking in /in/E051B on line 7
Process exited with code 255. - Output for 5.5.0 - 5.5.35
- Parse error: syntax error, unexpected '.', expecting '&' or variable (T_VARIABLE) in /in/E051B on line 3
Process exited with code 255.
preferences:
189.51 ms | 1395 KiB | 71 Q