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.
30 linhas
519 B
PHP
30 linhas
519 B
PHP
<?php
|
|
|
|
$n = 10;
|
|
$vals = array();
|
|
$a = array();
|
|
|
|
function main() {
|
|
for ($i = 0; $i < 10; $i++) {
|
|
$vals[] = $GLOBALS['n'];
|
|
}
|
|
var_dump($vals);
|
|
|
|
for ($i = 0; $i < 10; $i++) {
|
|
$gname = "a" . (string)$i;
|
|
$GLOBALS[$gname] = $i;
|
|
}
|
|
|
|
printf("%016x\n", 1 << $GLOBALS['a0']);
|
|
printf("%016x\n", 1 << $GLOBALS['a1']);
|
|
printf("%016x\n", 1 << $GLOBALS['a2']);
|
|
printf("%016x\n", 1 << $GLOBALS['a3']);
|
|
|
|
$GLOBALS[42] = "---42---";
|
|
$a[] = $GLOBALS[42];
|
|
$a[] = $GLOBALS["42"];
|
|
var_dump($a);
|
|
}
|
|
|
|
main();
|