#35525 [Opn->Bgs]: static + heredoc = parse error
| From: | johannes@php.net | Date: | Fri, 02 Dec 2005 17:54:09 +0000 |
| Subject: | #35525 [Opn->Bgs]: static + heredoc = parse error | ||
| References: | 1 | Groups: | php.bugs |
| Request: | Send a blank email to php-bugs+get-89653@lists.php.net to get a copy of this message | ||
ID: 35525
Updated by: johannes@php.net
Reported By: snoyes at gmail dot com
-Status: Open
+Status: Bogus
Bug Type: Scripting Engine problem
Operating System: Windows XP
PHP Version: 5.1.1
New Comment:
Thank you for taking the time to write to us, but this is not
a bug. Please double-check the documentation available at
http://www.php.net/manual/ and the instructions on how to
report
a bug at http://bugs.php.net/how-to-report.php
.
Previous Comments:
------------------------------------------------------------------------
[2005-12-02 18:50:25] snoyes at gmail dot com
Description:
------------
Cannot assign static variables using heredoc. The manual indicates
heredoc is a string delimiter, interchangable with double quotes. When
assigning to static variables, it acts like an expression.
Reproduce code:
---------------
<?php
static $x <<<TEXT
any text here
TEXT;
echo $x;
?>
Expected result:
----------------
any text here
Actual result:
--------------
Parse error: parse error, unexpected T_START_HEREDOC, expecting ',' or
';' in [file] on line 3
------------------------------------------------------------------------
--
Edit this bug report at http://bugs.php.net/?id=35525&edit=1