Arquivos
hhvm/hphp/test/quick/selfparent.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

24 linhas
438 B
PHP

<?php
class B {
const MYCONST = "B::MYCONST";
public static function foo() {
echo "B::foo\n";
}
}
class C extends B {
const MYCONST = "C::MYCONST";
public static function foo() {
echo "C::foo\n";
}
public static function test() {
$arr = array('foo');
self::foo();
parent::foo();
self::$arr[0]();
parent::$arr[0]();
echo self::MYCONST . "\n";
echo parent::MYCONST . "\n";
}
}
C::test();