/
vshmidt
/
php
Обзор
Документация
Войти
/
vshmidt
/
php
Код
Запросы
0
Задачи
Вики
Пакеты
0
Релизы
0
Аналитика
Безопасность
master
ext/reflection/tests/bug36434.phpt
31 строка
533 B
DanielEScherzer
ext/reflection: fix some typos [skip ci] (#16183)
03 окт 2024, 08:55
Не верифицирован
03 окт 2024, 08:55
8b8a673
Код
Авторство
О чём код?
--TEST-- Reflection Bug #36434 (Properties from parent class fail to identify their true origin) --FILE-- <?php class ancestor { public $ancestor = 0; function __construct() { return $this->ancestor; } } class foo extends ancestor { public $bar = "1"; function __construct() { return $this->bar; } } $r = new ReflectionClass('foo'); foreach ($r->GetProperties() as $p) { echo $p->getName(). " ". $p->getDeclaringClass()->getName()."\n"; } ?> --EXPECT-- bar foo ancestor ancestor