blob: 61aec5b1ce05bd0a56a542b3f62f4be83f3ff997 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
|
--TEST--
Bug #80299: ReflectionFunction->invokeArgs confused in arguments
--FILE--
<?php
$bar = new DateTime();
$args = [1, &$bar];
$function = function (int &$foo, DateTimeInterface &$bar) {};
(new ReflectionFunction($function))->invokeArgs($args);
?>
--EXPECTF--
Warning: {closure}(): Argument #1 ($foo) must be passed by reference, value given in %s on line %d
|