Skip to content

Commit f945687

Browse files
committed
Dataflow: Simplify branch and join.
1 parent 82afbbc commit f945687

File tree

1 file changed

+4
-6
lines changed

1 file changed

+4
-6
lines changed

shared/dataflow/codeql/dataflow/internal/DataFlowImpl.qll

Lines changed: 4 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1156,12 +1156,11 @@ module MakeImpl<LocationSig Location, InputSig<Location> Lang> {
11561156
* contexts.
11571157
*/
11581158
pragma[nomagic]
1159-
private int branch(NodeEx n1) {
1159+
private int branch(ArgNodeEx n1) {
11601160
result =
11611161
strictcount(DataFlowCallable c |
11621162
exists(NodeEx n |
1163-
flowOutOfCallNodeCand1(_, n1, _, n) or flowIntoCallNodeCand1(_, n1, n)
1164-
|
1163+
flowIntoCallNodeCand1(_, n1, n) and
11651164
c = n.getEnclosingCallable()
11661165
)
11671166
) + sum(ParamNodeEx p1 | | getLanguageSpecificFlowIntoCallNodeCand1(n1, p1))
@@ -1173,12 +1172,11 @@ module MakeImpl<LocationSig Location, InputSig<Location> Lang> {
11731172
* contexts.
11741173
*/
11751174
pragma[nomagic]
1176-
private int join(NodeEx n2) {
1175+
private int join(ParamNodeEx n2) {
11771176
result =
11781177
strictcount(DataFlowCallable c |
11791178
exists(NodeEx n |
1180-
flowOutOfCallNodeCand1(_, n, _, n2) or flowIntoCallNodeCand1(_, n, n2)
1181-
|
1179+
flowIntoCallNodeCand1(_, n, n2) and
11821180
c = n.getEnclosingCallable()
11831181
)
11841182
) + sum(ArgNodeEx arg2 | | getLanguageSpecificFlowIntoCallNodeCand1(arg2, n2))

0 commit comments

Comments
 (0)