Travis: Use simpleMatch for simple pattern

This commit is contained in:
Daniel Marjamäki 2020-02-16 21:47:46 +01:00
parent e789135344
commit 89cb0187d0
1 changed files with 1 additions and 1 deletions

View File

@ -912,7 +912,7 @@ static void compilePrecedence2(Token *&tok, AST_state& state)
const std::size_t oldOpSize = state.op.size();
compileExpression(tok, state);
tok = tok2;
if (Token::Match(tok->previous(), "} (")
if (Token::simpleMatch(tok->previous(), "} (")
|| (tok->previous() && tok->previous()->isName() && !Token::Match(tok->previous(), "return|case") && (!state.cpp || !Token::Match(tok->previous(), "throw|delete")))
|| (tok->strAt(-1) == "]" && (!state.cpp || !Token::Match(tok->linkAt(-1)->previous(), "new|delete")))
|| (tok->strAt(-1) == ">" && tok->linkAt(-1))