Arquivos
hhvm/hphp/test/vm/vector-variant-key.php
T
Jordan Delong 363d1bb20f Code move src/ -> hphp/
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.
2013-02-11 02:10:41 -08:00

21 linhas
333 B
PHP

<?php
class asshat {
private $prop;
public function __construct(&$v) {
$this->prop =& $v;
}
public function __get($k) {
$this->prop = 'foo';
return array('foo' => 'gotcha', 1 => 'whoops');
}
}
function main($cond) {
$x = 1;
$o = new asshat($x);
if ($cond) {
var_dump($o->blah[$x]);
}
}
main(true);