Tokenizer::simplifyKnownVariables: Fixed TODO test case.
This commit is contained in:
parent
694853249f
commit
13c2a73d3f
|
@ -5982,7 +5982,8 @@ bool Tokenizer::simplifyKnownVariables()
|
|||
}
|
||||
|
||||
// Variable is used in calculation..
|
||||
if (Token::Match(tok3, "[=+-*/[] %varid% [=?+-*/;])]", varid) ||
|
||||
if (((tok3->previous()->varId() > 0) && Token::Match(tok3, "& %varid%", varid)) ||
|
||||
Token::Match(tok3, "[=+-*/[] %varid% [=?+-*/;])]", varid) ||
|
||||
Token::Match(tok3, "[(=+-*/[] %varid% <<|>>", varid) ||
|
||||
Token::Match(tok3, "<< %varid% [+-*/;])]", varid) ||
|
||||
Token::Match(tok3, ">> %varid% [+-*/;])]", varid) ||
|
||||
|
|
|
@ -1598,7 +1598,7 @@ private:
|
|||
"4:\n"
|
||||
"5: return u@1 & v@2 ;\n"
|
||||
"6: }\n";
|
||||
TODO_ASSERT_EQUALS(expected, tokenizeDebugListing(code, true));
|
||||
ASSERT_EQUALS(expected, tokenizeDebugListing(code, true));
|
||||
}
|
||||
|
||||
{
|
||||
|
|
Loading…
Reference in New Issue