Bug #67766 [Opn->Csd]: Inaccuracies in Program Structure
| From: | stas@php.net | Date: | Sun, 28 Jun 2015 20:59:48 +0000 |
| Subject: | Bug #67766 [Opn->Csd]: Inaccuracies in Program Structure | ||
| References: | 1 | Groups: | php.standards |
| Request: | Send a blank email to standards-+get-812@lists.php.net to get a copy of this message | ||
Edit report at https://bugs.php.net/bug.php?id=67766&edit=1
ID: 67766
Updated by: stas@php.net
Reported by: joelm at fb dot com
Summary: Inaccuracies in Program Structure
-Status: Open
+Status: Closed
Type: Bug
Package: PHP Language Specification
PHP Version: Irrelevant
-Assigned To:
+Assigned To: stas
Block user comment: N
Private report: N
New Comment:
The fix for this bug has been committed.
Snapshots of the sources are packaged every three hours; this change
will be in the next snapshot. You can grab the snapshot at
http://snaps.php.net/.
For Windows:
http://windows.php.net/snapshots/
Thank you for the report, and for helping us make PHP better.
This seems to be already fixed.
Previous Comments:
------------------------------------------------------------------------
[2014-08-05 16:15:49] joelm at fb dot com
Description:
------------
https://github.com/php/php-langspec/blob/master/spec/04-basic-concepts.md#program-structure
The "<?php" open tag doesn't have to be at the top of the file, it can come later,
and technically a PHP file might not have any tags at all. Also, after the "?>" close
tag there can be more stuff and possible another open tag "<?php". Finally, there are
some interesting things like how "<?" (with the "php" part) work as an open
tag, and how "<script language='php'>" can also work as an open tag. Stuff
that appears before the first open tag and stuff that appears after a close tag but before the next
open tag is treated as content that is echo'd out when the flow of execution reaches it.
Some of this has been addressed by changing the grammar for the syntactic grammar production
âprogramâ.
------------------------------------------------------------------------
--
Edit this bug report at https://bugs.php.net/bug.php?id=67766&edit=1