ID: 32842
Updated by: [EMAIL PROTECTED]
Reported By: rael at grad dot icmc dot usp dot br
-Status: Open
+Status: Bogus
Bug Type: Feature/Change Request
Operating System: Windows XP Professional with SP2
PHP Version: 5.0.4
New Comment:
Duplicate of bug #27022.
Previous Comments:
------------------------------------------------------------------------
[2005-04-26 15:13:49] rael at grad dot icmc dot usp dot br
Description:
------------
In a class, a constant cannot have visibility modifiers.
This is weird. In other languages, like Java, constants can be public
or private, etc.
Reproduce code:
---------------
<?
class MyClass{
private const foo = "foo";
}
?>
Expected result:
----------------
No runtime errors.
Actual result:
--------------
Parse error: syntax error, unexpected T_CONST, expecting T_VARIABLE in
D:\Develop\www\teste\const.php on line 4
------------------------------------------------------------------------
--
Edit this bug report at http://bugs.php.net/?id=32842&edit=1