This commit is contained in:
Paul 2020-09-10 22:59:19 -05:00
parent 71bc79ac28
commit c568e8ea78
1 changed files with 2 additions and 1 deletions

View File

@ -247,7 +247,8 @@ bool isTemporary(bool cpp, const Token* tok, const Library* library, bool unknow
return false;
if (Token::Match(tok, "&|<<|>>") && isLikelyStream(cpp, tok->astOperand1()))
return false;
if (Token::simpleMatch(tok, "(") && tok->astOperand1() && (tok->astOperand2() || Token::simpleMatch(tok->next(), ")"))) {
if (Token::simpleMatch(tok, "(") && tok->astOperand1() &&
(tok->astOperand2() || Token::simpleMatch(tok->next(), ")"))) {
if (tok->valueType()) {
return tok->valueType()->reference == Reference::None;
}