#39067 [NEW]: getDeclaringClass and private attrs
From: dave at dgx dot cz
Operating system:
PHP version: 5.2.0RC5
PHP Bug Type: SPL related
Bug description: getDeclaringClass and private attrs
Description:
------------
ReflectionProperty::getDeclaringClass
Reproduce code:
---------------
class A {
private $x;
}
class B extends A {
private $x;
}
$rc = new ReflectionClass('B');
echo $rc->getProperty('x')->getDeclaringClass()->getName();
Expected result:
----------------
B
Actual result:
--------------
A
--
Edit bug report at http://bugs.php.net/?id=39067&edit=1
--
Try a CVS snapshot (PHP 4.4): http://bugs.php.net/fix.php?id=39067&r=trysnapshot44
Try a CVS snapshot (PHP 5.2): http://bugs.php.net/fix.php?id=39067&r=trysnapshot52
Try a CVS snapshot (PHP 6.0): http://bugs.php.net/fix.php?id=39067&r=trysnapshot60
Fixed in CVS: http://bugs.php.net/fix.php?id=39067&r=fixedcvs
Fixed in release: http://bugs.php.net/fix.php?id=39067&r=alreadyfixed
Need backtrace: http://bugs.php.net/fix.php?id=39067&r=needtrace
Need Reproduce Script: http://bugs.php.net/fix.php?id=39067&r=needscript
Try newer version: http://bugs.php.net/fix.php?id=39067&r=oldversion
Not developer issue: http://bugs.php.net/fix.php?id=39067&r=support
Expected behavior: http://bugs.php.net/fix.php?id=39067&r=notwrong
Not enough info: http://bugs.php.net/fix.php?id=39067&r=notenoughinfo
Submitted twice: http://bugs.php.net/fix.php?id=39067&r=submittedtwice
register_globals: http://bugs.php.net/fix.php?id=39067&r=globals
PHP 3 support discontinued: http://bugs.php.net/fix.php?id=39067&r=php3
Daylight Savings: http://bugs.php.net/fix.php?id=39067&r=dst
IIS Stability: http://bugs.php.net/fix.php?id=39067&r=isapi
Install GNU Sed: http://bugs.php.net/fix.php?id=39067&r=gnused
Floating point limitations: http://bugs.php.net/fix.php?id=39067&r=float
No Zend Extensions: http://bugs.php.net/fix.php?id=39067&r=nozend
MySQL Configuration Error: http://bugs.php.net/fix.php?id=39067&r=mysqlcfg
Thread (2 messages)
- dave at dgx dot cz