#38194 [Asn->Csd]: ReflectionClass::isSubclassOf() returns TRUE for the class itself
| From: | iliaa@php.net | Date: | Tue, 25 Jul 2006 12:36:41 +0000 |
| Subject: | #38194 [Asn->Csd]: ReflectionClass::isSubclassOf() returns TRUE for the class itself | ||
| References: | 1 | Groups: | php.bugs |
| Request: | Send a blank email to php-bugs+get-99863@lists.php.net to get a copy of this message | ||
ID: 38194
Updated by: iliaa@php.net
Reported By: alex at kiesel dot name
-Status: Assigned
+Status: Closed
Bug Type: Unknown/Other Function
Operating System: FreeBSD 6.0
PHP Version: 5.1.4
Assigned To: helly
New Comment:
This bug has been fixed in CVS.
Snapshots of the sources are packaged every three hours; this change
will be in the next snapshot. You can grab the snapshot at
http://snaps.php.net/.
Thank you for the report, and for helping us make PHP better.
Previous Comments:
------------------------------------------------------------------------
[2006-07-24 15:01:09] alex at kiesel dot name
Description:
------------
The ReflectionClass::isSubclassOf() returns TRUE when passing a
ReflectionClass object of the same class as parameter. A class is not a
subclass of itself, however.
Reproduce code:
---------------
<?php
class Object { }
$objectClass= new ReflectionClass('Object');
var_dump($objectClass->isSubclassOf($objectClass));
?>
Expected result:
----------------
bool(false)
Actual result:
--------------
bool(true)
------------------------------------------------------------------------
--
Edit this bug report at http://bugs.php.net/?id=38194&edit=1