Merge pull request #4701 from yoff/python-fix-return-node-enclosing-callable

Python: Use default `getEnclosingCallable` for `RetrunNode`
This commit is contained in:
Rasmus Wriedt Larsen
2020-11-25 10:36:41 +01:00
committed by GitHub
4 changed files with 15 additions and 6 deletions

View File

@@ -739,10 +739,6 @@ class ReturnNode extends CfgNode {
/** Gets the kind of this return node. */
ReturnKind getKind() { any() }
override DataFlowCallable getEnclosingCallable() {
result.getScope().getAStmt() = ret // TODO: check nested function definitions
}
}
/** A data flow node that represents the output of a call. */