ID:               34390
 Updated by:       [EMAIL PROTECTED]
 Reported By:      cbelin at free dot fr
-Status:           Open
+Status:           Closed
 Bug Type:         Documentation problem
 Operating System: Windows XP SP2
 PHP Version:      5.0.4
 New Comment:

This bug has been fixed in the documentation's XML sources. Since the
online and downloadable versions of the documentation need some time
to get updated, we would like to ask you to be a bit patient.

Thank you for the report, and for helping us make our documentation
better.




Previous Comments:
------------------------------------------------------------------------

[2005-09-12 13:38:55] [EMAIL PROTECTED]

Reclassified as docu bug.

------------------------------------------------------------------------

[2005-09-12 11:37:54] [EMAIL PROTECTED]

This is documentation bug.

------------------------------------------------------------------------

[2005-09-07 11:54:31] [EMAIL PROTECTED]

Dmitry, shouldn't this procude an error..?


------------------------------------------------------------------------

[2005-09-06 13:49:50] cbelin at free dot fr

Description:
------------
Manual says that static members and methods cannot be redefined in
subclasses.

It seems that it's not completely true (at least with PHP 5.0.4 under
Windows XP), as redefining static methods in subclasses is allowed, and
works fine (i.e. without triggering errors even if error level includes
E_STRICT).


Reproduce code:
---------------
class Base
{
   public static function foo()
   {
      return 'Foo...';
   }
}

class Extended extends Base
{
   public static function foo()
   {
      return 'Bar !!!';
   }
}

echo Extended::foo();

Expected result:
----------------
An error, or the output of Base::foo()

Actual result:
--------------
It works, and prints 'Bar !!!'


------------------------------------------------------------------------


-- 
Edit this bug report at http://bugs.php.net/?id=34390&edit=1

Reply via email to