Arquivos
hhvm/hphp/test/quick/exceptions2.php
T
ptarjan 503f75d08b Rename test directories
These names don't make sense now that we run both suites the same
way.
2013-04-17 09:06:51 -07:00

25 linhas
389 B
PHP

<?php
function newobj() {
return new C;
}
class C {
public function __destruct() {
global $y;
$y = false;
echo "C::__destruct\n";
}
public function g($x, $y, $z) {
return $y;
}
public function foo($z) {
$w1 = 1;
$w2 = 2;
newobj()->g("hi", $w1, 7, 8, $w2 = $this->foo(newobj()));
}
}
function bar() {
$obj = new C;
newobj()->foo(123);
}
bar();