xref: /PHP-8.4/Zend/tests/gh16515.phpt (revision 8720063c)
1--TEST--
2GH-16515: Incorrect propagation of ZEND_ACC_RETURN_REFERENCE for call trampoline
3--FILE--
4<?php
5
6namespace Foo;
7
8class Foo {
9    public function &__call($method, $args) {}
10}
11
12call_user_func((new Foo)->bar(...));
13
14?>
15--EXPECTF--
16Notice: Only variable references should be returned by reference in %s on line %d
17