Skip to content

Commit

Permalink
Simplification
Browse files Browse the repository at this point in the history
  • Loading branch information
ondrejmirtes committed Aug 3, 2023
1 parent 6b6fdaa commit 846ae76
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions src/Parser/ConstExprParser.php
Original file line number Diff line number Diff line change
Expand Up @@ -273,10 +273,8 @@ private function parseArray(TokenIterator $tokens, int $endToken, int $startInde
* This method is supposed to be called with TokenIterator after reading TOKEN_DOUBLE_QUOTED_STRING and shifting
* to the next token.
*/
public function parseDoctrineString(string $value, TokenIterator $tokens): Ast\ConstExpr\DoctrineConstExprStringNode
public function parseDoctrineString(string $text, TokenIterator $tokens): Ast\ConstExpr\DoctrineConstExprStringNode
{
$text = $value;

// Because of how Lexer works, a valid Doctrine string
// can consist of a sequence of TOKEN_DOUBLE_QUOTED_STRING and TOKEN_DOCTRINE_ANNOTATION_STRING
while ($tokens->isCurrentTokenType(Lexer::TOKEN_DOUBLE_QUOTED_STRING, Lexer::TOKEN_DOCTRINE_ANNOTATION_STRING)) {
Expand Down

0 comments on commit 846ae76

Please sign in to comment.