From: Ilia Alshanetsky Date: Wed, 22 Feb 2006 15:45:25 +0000 (+0000) Subject: Added test for bug #36434 X-Git-Tag: php-5.1.3RC1~82 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=07e7092729b94f8de24ff96d3a876d0da4eaebc2;p=php Added test for bug #36434 --- diff --git a/ext/reflection/tests/bug36434.phpt b/ext/reflection/tests/bug36434.phpt new file mode 100644 index 0000000000..c92c358a29 --- /dev/null +++ b/ext/reflection/tests/bug36434.phpt @@ -0,0 +1,31 @@ +--TEST-- +Bug #36434 (Properties from parent class fail to indetify their true origin) +--FILE-- +ancester; + } +} +class foo extends ancester +{ +public $bar = "1"; + function foo() + { + return $this->bar; + } +} + +$r = new ReflectionClass('foo'); +foreach ($r->GetProperties() as $p) +{ + echo $p->getName(). " ". $p->getDeclaringClass()->getName()."\n"; +} + +?> +--EXPECT-- +bar foo +ancester ancester