CheckFunctions::checkIgnoredReturnValue: Dont warn in C++11 initializer lists in function arguments

This commit is contained in:
Daniel Marjamäki 2017-04-02 19:44:27 +02:00
parent f7bfbee809
commit de80d41ef4
1 changed files with 1 additions and 1 deletions

View File

@ -157,7 +157,7 @@ void CheckFunctions::checkIgnoredReturnValue()
const Scope * scope = symbolDatabase->functionScopes[i];
for (const Token* tok = scope->classStart->next(); tok != scope->classEnd; tok = tok->next()) {
// skip c++11 initialization, ({...})
if (Token::Match(tok, "%var%|( {"))
if (Token::Match(tok, "%var%|(|, {"))
tok = tok->linkAt(1);
if (tok->varId() || !Token::Match(tok, "%name% ("))