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.
37 linhas
629 B
PHP
37 linhas
629 B
PHP
<?php
|
|
function g($obj) {
|
|
echo "g\n";
|
|
$obj->yar(123);
|
|
}
|
|
class D {
|
|
public function yar($y) {
|
|
$x = $y;
|
|
}
|
|
public function __destruct() {
|
|
$x = 1;
|
|
call_user_func('g', $this);
|
|
}
|
|
}
|
|
class C {
|
|
public function baz($z) {
|
|
$guard = new D;
|
|
$x = 1;
|
|
return $z = call_user_func(array($this,'foo'), $z);
|
|
}
|
|
public function bar($z) {
|
|
$guard = new D;
|
|
$x = 1;
|
|
return $z = call_user_func(array($this,'baz'), $z);
|
|
}
|
|
public function foo($z) {
|
|
$guard = new D;
|
|
$x = 1;
|
|
return $z = call_user_func(array($this,'bar'), $z);
|
|
}
|
|
}
|
|
function bar() {
|
|
$obj = new C;
|
|
$obj->foo(123);
|
|
}
|
|
bar();
|