363d1bb20f
This change is mostly for FB internal organizational reasons. Building is not effected beyond the fact that the target now lands in hphp/hhvm/hhvm rather than src/hhvm/hhvm.
26 linhas
392 B
PHP
26 linhas
392 B
PHP
<?php
|
|
|
|
print "Test begin\n";
|
|
|
|
# Get a key that doesn't exist in $GLOBALS.
|
|
$k = 'k';
|
|
while (isset($GLOBALS[$k])) {
|
|
$k .= 'k';
|
|
}
|
|
|
|
$a = $GLOBALS;
|
|
$GLOBALS[$k] = 42;
|
|
if (isset($GLOBALS[$k])) {
|
|
print "Key is set in \$GLOBALS\n";
|
|
}
|
|
if (isset($a[$k])) {
|
|
print "Key set visible via \$a\n";
|
|
}
|
|
$b = $a;
|
|
$a[$k]++;
|
|
if ($b[$k] == 43) {
|
|
print "Key update visible via \$b\n";
|
|
}
|
|
|
|
print "Test end\n";
|