Skip to content

Commit 749e813

Browse files
committed
Python: Allow multiple **kwargs parameters outside our test code
1 parent b6272b3 commit 749e813

File tree

1 file changed

+9
-0
lines changed

1 file changed

+9
-0
lines changed

python/ql/test/experimental/dataflow/TestUtil/DataFlowConsistency.qll

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,15 @@ private class MyConsistencyConfiguration extends ConsistencyConfiguration {
2020
n instanceof SynthDictSplatParameterNode
2121
}
2222

23+
override predicate uniqueParameterNodeAtPositionExclude(
24+
DataFlowCallable c, ParameterPosition pos, Node p
25+
) {
26+
// TODO: This can be removed once we solve the overlap of dictionary splat parameters
27+
c.getParameter(pos) = p and
28+
pos.isDictSplat() and
29+
not exists(p.getLocation().getFile().getRelativePath())
30+
}
31+
2332
override predicate uniqueParameterNodePositionExclude(
2433
DataFlowCallable c, ParameterPosition pos, Node p
2534
) {

0 commit comments

Comments
 (0)