Cache and reuse value
This commit is contained in:
parent
3b4f60fd21
commit
4663dc205a
|
@ -1995,8 +1995,9 @@ static bool isStdMoveOrStdForwarded(Token * tok, ValueFlow::Value::MoveKind * mo
|
||||||
|
|
||||||
static bool isOpenParenthesisMemberFunctionCallOfVarId(const Token * openParenthesisToken, unsigned int varId)
|
static bool isOpenParenthesisMemberFunctionCallOfVarId(const Token * openParenthesisToken, unsigned int varId)
|
||||||
{
|
{
|
||||||
return Token::Match(openParenthesisToken->tokAt(-3),"%varid% . %name% (", varId) &&
|
const Token * varTok = openParenthesisToken->tokAt(-3);
|
||||||
openParenthesisToken->tokAt(-2)->originalName() == emptyString;
|
return Token::Match(varTok, "%varid% . %name% (", varId) &&
|
||||||
|
varTok->next()->originalName() == emptyString;
|
||||||
}
|
}
|
||||||
|
|
||||||
static const Token * nextAfterAstRightmostLeaf(Token const * tok)
|
static const Token * nextAfterAstRightmostLeaf(Token const * tok)
|
||||||
|
|
Loading…
Reference in New Issue