mirror of
https://github.com/php/php-src.git
synced 2025-01-09 20:44:33 +08:00
75bc3446f8
All these tests are meant to run with OPcache available, and some will even fail inevitably without it, so we add OPcache as SKIPIF requirement.
25 lines
309 B
PHP
25 lines
309 B
PHP
--TEST--
|
|
Inlining of functions with ref arguments
|
|
--SKIPIF--
|
|
<?php require_once('skipif.inc'); ?>
|
|
--FILE--
|
|
<?php
|
|
|
|
function by_ref(&$var)
|
|
{
|
|
}
|
|
function &get_array() {
|
|
$array = [new stdClass];
|
|
return $array;
|
|
}
|
|
function test()
|
|
{
|
|
by_ref(get_array()[0]);
|
|
print "ok!\n";
|
|
}
|
|
test();
|
|
|
|
?>
|
|
--EXPECT--
|
|
ok!
|