Skip to content

Commit

Permalink
Add doctrine/lexer v3 compatibility
Browse files Browse the repository at this point in the history
Using the token as Token object is compatible with both v2 and v3 of doctrine/lexer
  • Loading branch information
zanardigit authored Oct 24, 2024
1 parent 17d1ee1 commit 77d2dfc
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/Doctrine/Query/Cast.php
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ public function parse(Parser $parser): void
$this->first = $parser->ArithmeticPrimary();
$parser->match(Lexer::T_AS);
$parser->match(Lexer::T_IDENTIFIER);
$this->second = $parser->getLexer()->token['value'];
$this->second = $parser->getLexer()->token->value;

Check failure on line 55 in src/Doctrine/Query/Cast.php

View workflow job for this annotation

GitHub Actions / PHPStan

Cannot access property $value on array<string, int|string|null>.

Check failure on line 55 in src/Doctrine/Query/Cast.php

View workflow job for this annotation

GitHub Actions / PHPStan

Cannot access property $value on array<string, int|string|null>.
$parser->match(Lexer::T_CLOSE_PARENTHESIS);
}
}

0 comments on commit 77d2dfc

Please sign in to comment.