Skip to content

Commit bf72aa3

Browse files
Update tokenize.cpp
1 parent f815ce3 commit bf72aa3

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

lib/tokenize.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9146,8 +9146,6 @@ void Tokenizer::findGarbageCode() const
91469146
if (!tok2->next() || tok2->isControlFlowKeyword() || Token::Match(tok2, "typedef|static|."))
91479147
syntaxError(tok);
91489148
if (Token::Match(tok2, "%name% %name%")) {
9149-
if (Token::Match(tok2->tokAt(2), "%name%") && !(tok2->isKeyword() || tok2->tokAt(1)->isKeyword() || tok2->tokAt(2)->isKeyword()))
9150-
syntaxError(tok2);
91519149
if (tok2->str() == tok2->strAt(1)) {
91529150
if (Token::simpleMatch(tok2->tokAt(2), ";"))
91539151
continue;
@@ -9157,6 +9155,8 @@ void Tokenizer::findGarbageCode() const
91579155
continue;
91589156
syntaxError(tok2);
91599157
}
9158+
if (Token::Match(tok2->tokAt(2), "%name%") && !(tok2->isKeyword() || tok2->tokAt(1)->isKeyword() || tok2->tokAt(2)->isKeyword()))
9159+
syntaxError(tok2);
91609160
}
91619161
}
91629162
}

0 commit comments

Comments
 (0)