Use Token::simpleMatch for simple patterns
"internal" check reported: [lib/checkuninitvar.cpp:1101]: (warning) Found simple pattern inside Token::Match() call: "if ("
This commit is contained in:
parent
a1da067b88
commit
72a40b4da4
|
@ -1101,7 +1101,7 @@ void CheckUninitVar::checkScope(const Scope* scope)
|
|||
|
||||
static void conditionAlwaysTrueOrFalse(const Token *tok, const std::map<unsigned int, int> &variableValue, bool *alwaysTrue, bool *alwaysFalse)
|
||||
{
|
||||
assert(Token::Match(tok, "if ("));
|
||||
assert(Token::simpleMatch(tok, "if ("));
|
||||
|
||||
const Token *vartok = tok->tokAt(2);
|
||||
const bool NOT(vartok->str() == "!");
|
||||
|
|
Loading…
Reference in New Issue