Merge pull request #15853 from hvitved/dataflow/get-location

Data flow: Replace `hasLocationInfo` with `getLocation`
This commit is contained in:
Tom Hvitved
2024-03-18 20:21:46 +01:00
committed by GitHub
96 changed files with 419 additions and 277 deletions

View File

@@ -10,12 +10,16 @@ private import semmle.python.dataflow.new.internal.DataFlowDispatch
private import semmle.python.dataflow.new.internal.TaintTrackingImplSpecific
private import codeql.dataflow.internal.DataFlowImplConsistency
private module Input implements InputSig<PythonDataFlow> {
private module Input implements InputSig<Location, PythonDataFlow> {
private import Private
private import Public
predicate postWithInFlowExclude(Node n) { n instanceof FlowSummaryNode }
predicate uniqueNodeLocationExclude(Node n) { n instanceof FlowSummaryNode }
predicate missingLocationExclude(Node n) { n instanceof FlowSummaryNode }
predicate argHasPostUpdateExclude(ArgumentNode n) {
// TODO: Implement post-updates for *args, see tests added in https://github.com/github/codeql/pull/14936
exists(ArgumentPosition apos | n.argumentOf(_, apos) and apos.isStarArgs(_))
@@ -132,4 +136,4 @@ private module Input implements InputSig<PythonDataFlow> {
}
}
import MakeConsistency<PythonDataFlow, PythonTaintTracking, Input>
import MakeConsistency<Location, PythonDataFlow, PythonTaintTracking, Input>