Preprocessor: Use %oror% in multiCompare pattern

This commit is contained in:
Daniel Marjamäki 2011-04-10 11:50:19 +02:00
parent e94e3eca82
commit 76679255a3
1 changed files with 1 additions and 1 deletions

View File

@ -1505,7 +1505,7 @@ void Preprocessor::simplifyCondition(const std::map<std::string, std::string> &v
for (Token *tok = const_cast<Token *>(tokenizer.tokens()); tok; tok = tok->next())
{
while ((tok->str() == "(" || tok->str() == "||") && (Token::simpleMatch(tok->tokAt(2), "|| 1")))
while (Token::Match(tok, "(|%oror% %any% %oror% 1"))
{
tok->deleteNext();
tok->deleteNext();