More selective match pattern
This commit is contained in:
parent
fe0a514a7c
commit
7d6ef71c4d
|
@ -178,7 +178,7 @@ bool CheckCondition::assignIfParseScope(const Token * const assignTok,
|
||||||
if (Token::Match(tok2, "[(,] &| %varid% [,)]", varid)) {
|
if (Token::Match(tok2, "[(,] &| %varid% [,)]", varid)) {
|
||||||
return true;
|
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 Token *vartok = tok2->next();
|
||||||
const std::string& op(vartok->strAt(1));
|
const std::string& op(vartok->strAt(1));
|
||||||
const MathLib::bigint num2 = MathLib::toLongNumber(vartok->strAt(2));
|
const MathLib::bigint num2 = MathLib::toLongNumber(vartok->strAt(2));
|
||||||
|
|
Loading…
Reference in New Issue