rfc:flexible_heredoc_nowdoc_syntaxes
Differences
This shows you the differences between two versions of the page.
Both sides previous revisionPrevious revisionNext revision | Previous revision |
rfc:flexible_heredoc_nowdoc_syntaxes [2017/11/02 11:32] – tpunt | rfc:flexible_heredoc_nowdoc_syntaxes [2018/04/13 19:59] (current) – Implementation landed nikic |
---|
* Date: 2017-09-16 | * Date: 2017-09-16 |
* Author: Thomas Punt, tpunt@php.net | * Author: Thomas Punt, tpunt@php.net |
* Status: Voting | * Status: Implemented (in PHP 7.3) |
* First Published at: https://wiki.php.net/rfc/flexible_heredoc_nowdoc_syntaxes | * First Published at: https://wiki.php.net/rfc/flexible_heredoc_nowdoc_syntaxes |
| |
</code> | </code> |
| |
This change was actually brought up in a previous RFC ([[rfc:heredoc-scanner-loosening|PHP RFC: Loosening heredoc/nowdoc scanner]]). One of the big gotchas that it mentioned, however, was that if the ending marker was found at the start of a line, then regardless of whether it was apart of another word, it would still be considered as the ending marker. For example, the following would not work (due to ''ENDING'' containing ''END''): | This change was actually brought up in a previous RFC ([[rfc:heredoc-scanner-loosening|PHP RFC: Loosening heredoc/nowdoc scanner]]). One of the big gotchas that it mentioned, however, was that if the ending marker was found at the start of a line, then regardless of whether it was a part of another word, it would still be considered as the ending marker. For example, the following would not work (due to ''ENDING'' containing ''END''): |
<code php> | <code php> |
$values = [<<<END | $values = [<<<END |
Voting starts on 2017.11.01 and ends on 2017.11.15. | Voting starts on 2017.11.01 and ends on 2017.11.15. |
| |
<doodle title="Allow for the closing marker to be indented and for the leading whitespace to be stripped?" auth="tpunt" voteType="single" closed="false"> | <doodle title="Allow for the closing marker to be indented and for the leading whitespace to be stripped?" auth="tpunt" voteType="single" closed="true"> |
* Yes | * Yes |
* No | * No |
</doodle> | </doodle> |
'''' | '''' |
<doodle title="Remove the trailing new line requirement from the closing marker?" auth="tpunt" voteType="single" closed="false"> | <doodle title="Remove the trailing new line requirement from the closing marker?" auth="tpunt" voteType="single" closed="true"> |
* Yes | * Yes |
* No | * No |
rfc/flexible_heredoc_nowdoc_syntaxes.1509622335.txt.gz · Last modified: 2017/11/02 11:32 by tpunt