mirror of
https://github.com/php/php-src.git
synced 2024-09-22 10:27:25 +00:00
904c1b6589
The must_wrap was leaking across iterations.
16 lines
368 B
PHP
16 lines
368 B
PHP
--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
|