Arquivos
hhvm/hphp/test/vm/fsc02.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

22 linhas
371 B
PHP

<?php
class B {
public function f1() {
var_dump(get_called_class());
if ($this !== null) {
var_dump(get_class($this));
} else {
var_dump(null);
}
echo "\n";
}
}
class C extends B {
public function g() {
$obj = new B;
forward_static_call(array('B', 'f1'));
call_user_func(array('B', 'f1'));
}
}
$obj = new C;
$obj->g();