parent
ee8d5b972a
commit
1d6c0976e5
|
@ -1682,15 +1682,13 @@ bool isVariableChanged(const Token *tok, int indirect, const Settings *settings,
|
|||
return false;
|
||||
}
|
||||
|
||||
if (indirect > 0)
|
||||
{
|
||||
if (indirect > 0) {
|
||||
// check for `*(ptr + 1) = new_value` case
|
||||
parent = tok2->astParent();
|
||||
while (parent && parent->isArithmeticalOp() && parent->isBinaryOp()) {
|
||||
parent = parent->astParent();
|
||||
}
|
||||
if (Token::simpleMatch(parent, "*"))
|
||||
{
|
||||
if (Token::simpleMatch(parent, "*")) {
|
||||
if (parent->astParent() && parent->astParent()->isAssignmentOp() &&
|
||||
(parent->astParent()->astOperand1() == parent)) {
|
||||
return true;
|
||||
|
|
Loading…
Reference in New Issue