Php-parser: nowdoc have unnecessary property `quote`

Created on 27 Aug 2019  路  3Comments  路  Source: glayzzle/php-parser

The nowdoc syntax should be always use ' quotes, so this property is unnecessary.

enhancement help wanted question AST

All 3 comments

Nowdoc node is used with heredoc, and heredoc can use " or without any quote - https://www.php.net/manual/en/language.types.string.php#language.types.string.syntax.heredoc - the solution could be to create a new node heredoc with a quote property (as a boolean).

Right now we have nowdoc ast node where we have quote property, but we don't need this property because nowdow always require single quotes '

Fixed in prettier branch and will be merged in future (i hope)

Was this page helpful?
0 / 5 - 0 ratings

Related issues

Rivendall picture Rivendall  路  6Comments

nevadascout picture nevadascout  路  3Comments

takashiki picture takashiki  路  7Comments

alexander-akait picture alexander-akait  路  7Comments

alexander-akait picture alexander-akait  路  8Comments