|
php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login |
PatchesPull RequestsHistoryAllCommentsChangesGit/SVN commits
[2006-09-04 11:32 UTC] tony2001@php.net
|
|||||||||||||||||||||||||||
Copyright © 2001-2026 The PHP GroupAll rights reserved. |
Last updated: Tue Feb 10 17:00:02 2026 UTC |
Description: ------------ It seems that initializing static class member with constant expression generates a syntax error Reproduce code: --------------- <?php class C { static public $m = 1 + 2; // syntax error ! }; ?> Expected result: ---------------- There should not be any compilation error Actual result: -------------- PHP Parse error: syntax error, unexpected '(' in /var/www/html/test.php on line 3