We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent bd5ff18 commit 19ffa9fCopy full SHA for 19ffa9f
1 file changed
lib/tokenize.cpp
@@ -9018,8 +9018,8 @@ void Tokenizer::findGarbageCode() const
9018
syntaxError(tok);
9019
if (Token::Match(tok, "? %assign%"))
9020
9021
- if (Token::Match(tok, "!|~ %comp%") &&
9022
- !(cpp && tok->strAt(1) == ">" && Token::simpleMatch(tok->tokAt(-1), "operator")))
+ if (Token::Match(tok, "[!~+-/] %comp%") &&
+ !(cpp && Token::Match(tok->next(), "[<>]") && Token::simpleMatch(tok->tokAt(-1), "operator")))
9023
9024
if (Token::Match(tok, "%comp% {") && (!cpp || tok->str() != ">"))
9025
0 commit comments