@@ -1084,9 +1084,12 @@ module MakeImpl<InputSig Lang> {
1084
1084
pragma [ nomagic]
1085
1085
private int branch ( NodeEx n1 ) {
1086
1086
result =
1087
- strictcount ( NodeEx n |
1088
- flowOutOfCallNodeCand1 ( _, n1 , _, n ) or flowIntoCallNodeCand1 ( _, n1 , n )
1087
+ strictcount ( DataFlowCallable c | exists ( NodeEx n |
1088
+ flowOutOfCallNodeCand1 ( _, n1 , _, n ) or flowIntoCallNodeCand1 ( _, n1 , n ) | c = n . getEnclosingCallable ( ) )
1089
1089
) + sum ( ParamNodeEx p1 | | getLanguageSpecificFlowIntoCallNodeCand1 ( n1 , p1 ) )
1090
+ // strictcount(NodeEx n |
1091
+ // flowOutOfCallNodeCand1(_, n1, _, n) or flowIntoCallNodeCand1(_, n1, n)
1092
+ // ) + sum(ParamNodeEx p1 | | getLanguageSpecificFlowIntoCallNodeCand1(n1, p1))
1090
1093
}
1091
1094
1092
1095
/**
@@ -1097,9 +1100,12 @@ module MakeImpl<InputSig Lang> {
1097
1100
pragma [ nomagic]
1098
1101
private int join ( NodeEx n2 ) {
1099
1102
result =
1100
- strictcount ( NodeEx n |
1101
- flowOutOfCallNodeCand1 ( _, n , _, n2 ) or flowIntoCallNodeCand1 ( _, n , n2 )
1103
+ strictcount ( DataFlowCallable c | exists ( NodeEx n |
1104
+ flowOutOfCallNodeCand1 ( _, n , _, n2 ) or flowIntoCallNodeCand1 ( _, n , n2 ) | c = n . getEnclosingCallable ( ) )
1102
1105
) + sum ( ArgNodeEx arg2 | | getLanguageSpecificFlowIntoCallNodeCand1 ( arg2 , n2 ) )
1106
+ // strictcount(NodeEx n |
1107
+ // flowOutOfCallNodeCand1(_, n, _, n2) or flowIntoCallNodeCand1(_, n, n2)
1108
+ // ) + sum(ArgNodeEx arg2 | | getLanguageSpecificFlowIntoCallNodeCand1(arg2, n2))
1103
1109
}
1104
1110
1105
1111
/**
@@ -1114,10 +1120,11 @@ module MakeImpl<InputSig Lang> {
1114
1120
DataFlowCall call , RetNodeEx ret , ReturnKindExt kind , NodeEx out , boolean allowsFieldFlow
1115
1121
) {
1116
1122
flowOutOfCallNodeCand1 ( call , ret , kind , out ) and
1117
- exists ( int b , int j |
1118
- b = branch ( ret ) and
1123
+ exists ( int j | // b, int j |
1124
+ // b = branch(ret) and
1119
1125
j = join ( out ) and
1120
- if b .minimum ( j ) <= Config:: fieldFlowBranchLimit ( )
1126
+ // if b.minimum(j) <= Config::fieldFlowBranchLimit()
1127
+ if j <= Config:: fieldFlowBranchLimit ( )
1121
1128
then allowsFieldFlow = true
1122
1129
else allowsFieldFlow = false
1123
1130
)
0 commit comments