|
php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login |
PatchesPull RequestsHistoryAllCommentsChangesGit/SVN commits
[2005-06-22 17:56 UTC] tony2001@php.net
[2005-06-30 01:00 UTC] php-bugs at lists dot php dot net
|
|||||||||||||||||||||||||||
Copyright © 2001-2025 The PHP GroupAll rights reserved. |
Last updated: Tue Nov 04 23:00:01 2025 UTC |
Description: ------------ There is no way to shadowing (redeclare with another initialize value) the parent static/constant variables in the subclasses Reproduce code: --------------- <?php class Test1 { protected static $MAX = 100; } class Test2 extends Test1 { protected static $MAX = 200; } ?> Actual result: -------------- Fatal error: Cannot redeclare property static protected Test1::$MAX in class Test2 in D:\WebServerRoot\FrameWork\test.php on line 7