TypePHP 编译器 https://swoole.com/aot/
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 

28 lines
433 B

--TEST--
Test extract() for overwrite of GLOBALS
--SKIPIF--
<?php
if (true) die("skip AOT does not support extract()");
?>
--FILE--
<?php
$str = "John";
var_dump($GLOBALS["str"]);
/* Extracting Global Variables */
$splat = array("foo" => "bar");
var_dump(extract(array("GLOBALS" => $splat, EXTR_OVERWRITE)));
unset ($splat);
var_dump($GLOBALS["str"]);
echo "\nDone";
?>
--EXPECT--
string(4) "John"
int(1)
string(4) "John"
Done