Python: address review comments

This commit is contained in:
Rasmus Lerchedahl Petersen
2023-12-04 17:49:26 +01:00
parent f5c176bd12
commit 9e1c818db6
2 changed files with 1 additions and 3 deletions

View File

@@ -2,7 +2,7 @@ import python
import semmle.python.dataflow.new.DataFlow
private import semmle.python.dataflow.new.internal.DataFlowPrivate as DataFlowPrivate
/** Gets the EssaNode that holds the module imported by the fully qualified module name `name` */
/** Gets the `CfgNode` that holds the module imported by the fully qualified module name `name`. */
DataFlow::CfgNode module_import(string name) {
exists(Variable var, AssignmentDefinition def, Import imp, Alias alias |
var = def.getSourceVariable() and

View File

@@ -15,8 +15,6 @@ module InlinePoorMansFunctionResolutionTest implements TestSig {
not exists(FunctionDef def | def.getDefinedFunction() = func |
ref.asExpr() = def.getATarget()
) and
// exclude things like `GSSA variable func`
exists(ref.asExpr()) and
// exclude decorator calls (which with our extractor rewrites does reference the
// function)
not ref.asExpr() = func.getDefinition().(FunctionExpr).getADecoratorCall()