From: michiel at trendserver dot nl
Operating system: Debian
PHP version: 5.0.2
PHP Bug Type: Zend Engine 2 problem
Bug description: Wrong linenumber in ReflectionClass getStartLine()
Description:
------------
The Reflection API has a (minor) bug regarding the getStartLine() function
in ReflectionClass. When the reflected class is not a subclass and does not
implement any interfaces, the result of getStartLine() is one line off.
Reproduce code:
---------------
<?
class a
{
}
class b extends a
{
}
$ref1 = new ReflectionClass('a');
$ref2 = new ReflectionClass('b');
echo $ref1->getStartLine() . "\n";
echo $ref2->getStartLine() . "\n";
?>
Expected result:
----------------
2
6
Actual result:
--------------
3
6
--
Edit bug report at http://bugs.php.net/?id=30961&edit=1
--
Try a CVS snapshot (php4): http://bugs.php.net/fix.php?id=30961&r=trysnapshot4
Try a CVS snapshot (php5.0):
http://bugs.php.net/fix.php?id=30961&r=trysnapshot50
Try a CVS snapshot (php5.1):
http://bugs.php.net/fix.php?id=30961&r=trysnapshot51
Fixed in CVS: http://bugs.php.net/fix.php?id=30961&r=fixedcvs
Fixed in release: http://bugs.php.net/fix.php?id=30961&r=alreadyfixed
Need backtrace: http://bugs.php.net/fix.php?id=30961&r=needtrace
Need Reproduce Script: http://bugs.php.net/fix.php?id=30961&r=needscript
Try newer version: http://bugs.php.net/fix.php?id=30961&r=oldversion
Not developer issue: http://bugs.php.net/fix.php?id=30961&r=support
Expected behavior: http://bugs.php.net/fix.php?id=30961&r=notwrong
Not enough info:
http://bugs.php.net/fix.php?id=30961&r=notenoughinfo
Submitted twice:
http://bugs.php.net/fix.php?id=30961&r=submittedtwice
register_globals: http://bugs.php.net/fix.php?id=30961&r=globals
PHP 3 support discontinued: http://bugs.php.net/fix.php?id=30961&r=php3
Daylight Savings: http://bugs.php.net/fix.php?id=30961&r=dst
IIS Stability: http://bugs.php.net/fix.php?id=30961&r=isapi
Install GNU Sed: http://bugs.php.net/fix.php?id=30961&r=gnused
Floating point limitations: http://bugs.php.net/fix.php?id=30961&r=float
MySQL Configuration Error: http://bugs.php.net/fix.php?id=30961&r=mysqlcfg