<?php
class A
{
        function mA()
        {
                $this->nA();
        }

        static function mB()
        {
                self::nB();
        }
}

class B extends A
{
        function mA()
        {
                parent::mA();
        }

        static function mB()
        {
                parent::mB();
        }

        function nA()
        {
                echo 'A';
        }

        function nB()
        {
                echo 'B';
        }
}

$obj = new B();
$obj->mA();
B::mB();
?>

Most people will think, that it will output AB. But currently in PHP
5.2 (I don't have PHP 5.3 to test it) it will output:
A
Fatal error: Call to undefined method A::nb() in
Z:\localhost\testLSB.php on line 11

User that sees this, doesn't have any idea where is the problem and
how to find some information about it.

-- 
PHP Internals - PHP Runtime Development Mailing List
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to