1--TEST--
2First class callables should retain the signature for reflection
3--FILE--
4<?php
5
6function test(int $a, string &$b, Foo... $c) {}
7
8echo new ReflectionFunction(test(...));
9
10?>
11--EXPECTF--
12Closure [ <user> function test ] {
13  @@ %s 3 - 3
14
15  - Parameters [3] {
16    Parameter #0 [ <required> int $a ]
17    Parameter #1 [ <required> string &$b ]
18    Parameter #2 [ <optional> Foo ...$c ]
19  }
20}
21