C++: Remove omittable exists variables

This commit is contained in:
Tony Torralba
2022-12-21 16:17:49 +01:00
parent 16cd148961
commit 3fcc99e5cb
62 changed files with 484 additions and 579 deletions

View File

@@ -53,7 +53,7 @@ class Expr extends StmtParent, @expr {
Declaration getEnclosingDeclaration() { result = exprEnclosingElement(this) }
/** Gets a child of this expression. */
Expr getAChild() { exists(int n | result = this.getChild(n)) }
Expr getAChild() { result = this.getChild(_) }
/** Gets the parent of this expression, if any. */
Element getParent() { exprparents(underlyingElement(this), _, unresolveElement(result)) }