diff --git a/lib/checkcondition.cpp b/lib/checkcondition.cpp index 38e624e06..fd09fcca3 100644 --- a/lib/checkcondition.cpp +++ b/lib/checkcondition.cpp @@ -178,7 +178,7 @@ bool CheckCondition::assignIfParseScope(const Token * const assignTok, if (Token::Match(tok2, "[(,] &| %varid% [,)]", varid)) { return true; } - if (Token::Match(tok2,"&&|%oror%|( %varid% %any% %num% &&|%oror%|)", varid)) { + if (Token::Match(tok2,"&&|%oror%|( %varid% ==|!= %num% &&|%oror%|)", varid)) { const Token *vartok = tok2->next(); const std::string& op(vartok->strAt(1)); const MathLib::bigint num2 = MathLib::toLongNumber(vartok->strAt(2));