1 parent dfcec18 commit b226506Copy full SHA for b226506
1 file changed
lib/checkassert.cpp
@@ -78,6 +78,11 @@ void CheckAssertImpl::assertWithSideEffects()
78
continue;
79
}
80
81
+ const Token* parent = tmp->astParent();
82
+ while (Token::Match(parent, ".|::"))
83
+ parent = parent->astParent();
84
+ if (!Token::simpleMatch(parent, "("))
85
+ continue;
86
const Function* f = tmp->function();
87
const Scope* scope = f->functionScope;
88
if (!scope) {
0 commit comments