|
php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login |
PatchesPull RequestsHistoryAllCommentsChangesGit/SVN commits
[2013-12-10 08:55 UTC] laruence@php.net
-Assigned To:
+Assigned To: dmitry
[2013-12-10 08:55 UTC] laruence@php.net
[2013-12-10 10:21 UTC] dmitry@php.net
[2013-12-10 10:21 UTC] dmitry@php.net
-Status: Assigned
+Status: Closed
[2013-12-10 18:47 UTC] ab@php.net
|
|||||||||||||||||||||||||||
Copyright © 2001-2025 The PHP GroupAll rights reserved. |
Last updated: Fri Oct 24 02:00:01 2025 UTC |
Description: ------------ zval_update_constant_ex() evaluates a constant within the scope a class when executed within a class scope. The new code to support ASTs does not pass this context into the AST evaluator so the class context is lost and references to self::SOME_CONSTANT and parent::SOME_CONSTANT error. Test script: --------------- --TEST-- Terry_002 Problems in AST evaluation invalidating valid parent:: reference --INI-- opcache.enable=0 opcache.enable_cli=0 opcache.optimization_level=0 --SKIPIF-- --FILE-- <?php class A { const HW = "this is A"; } class B extends A { const BHW = parent::HW . " extended by B"; } const C = B::BHW; echo C, "\n"; --CLEAN-- --EXPECT-- this is A extended by B