Skip to content

Commit

Permalink
i love invalid but valid syntax, 'php -l' vs 'token_get_all'
Browse files Browse the repository at this point in the history
  • Loading branch information
keradus committed Dec 10, 2024
1 parent 26a5969 commit 25a1f78
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions src/Tokenizer/Transformer/BraceTransformer.php
Original file line number Diff line number Diff line change
Expand Up @@ -195,8 +195,9 @@ private function transformIntoPropertyHookBraces(Tokens $tokens, int $index): vo

private function transformIntoCurlyIndexBraces(Tokens $tokens, int $index): void
{
// as $arr{index} is illegal since 8.0
if (\PHP_VERSION_ID >= 8_00_00) {
// as $arr{index} is illegal since 8.4 - ParseError
// (and produces FatalError on 8.0-8.3)
if (\PHP_VERSION_ID >= 8_04_00) {
return;
}

Expand Down

0 comments on commit 25a1f78

Please sign in to comment.