Skip to content

Commit dee187f

Browse files
committed
fix
1 parent 646afb7 commit dee187f

1 file changed

Lines changed: 3 additions & 0 deletions

File tree

‎lib/tokenize.cpp‎

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9004,6 +9004,9 @@ void Tokenizer::findGarbageCode() const
90049004
else if (Token::Match(tok, "[`\\@]"))
90059005
syntaxError(tok);
90069006

9007+
else if (Token::Match(tok, ".|->") && !Token::Match(tok->next(), "%name%|~|*|::") && !Token::simpleMatch(tok->previous(), "operator"))
9008+
syntaxError(tok, tok->str() + tok->strAt(1));
9009+
90079010
// UNKNOWN_MACRO(return)
90089011
if (tok->isKeyword() && Token::Match(tok, "throw|return )") && Token::Match(tok->linkAt(1)->previous(), "%name% ("))
90099012
unknownMacroError(tok->linkAt(1)->previous());

0 commit comments

Comments
 (0)