mirror of
https://github.com/php/php-src.git
synced 2025-08-20 09:24:05 +02:00

We should use normal function renaming if the function is declared
during preloading itself, rather than afterwards.
This fixes a regression introduced by
68f80be9d1
.
18 lines
394 B
PHP
18 lines
394 B
PHP
--TEST--
|
|
Defining a dynamic function inside the preload script
|
|
--INI--
|
|
opcache.enable=1
|
|
opcache.enable_cli=1
|
|
opcache.optimization_level=-1
|
|
opcache.preload={PWD}/preload_dynamic_function.inc
|
|
--SKIPIF--
|
|
<?php
|
|
require_once('skipif.inc');
|
|
if (PHP_OS_FAMILY == 'Windows') die('skip Preloading is not supported on Windows');
|
|
?>
|
|
--FILE--
|
|
<?php
|
|
var_dump(function_exists("f"));
|
|
?>
|
|
--EXPECT--
|
|
bool(true)
|