@@ -2682,6 +2682,7 @@ module MakeImpl<InputSig Lang> {
2682
2682
) {
2683
2683
not isUnreachableInCall1 ( node2 , cc ) and
2684
2684
not inBarrier ( node2 , state ) and
2685
+ not outBarrier ( node1 , state ) and
2685
2686
(
2686
2687
localFlowEntry ( node1 , pragma [ only_bind_into ] ( state ) ) and
2687
2688
(
@@ -3761,6 +3762,9 @@ module MakeImpl<InputSig Lang> {
3761
3762
3762
3763
override NodeEx getNodeEx ( ) { result = node }
3763
3764
3765
+ pragma [ inline]
3766
+ final NodeEx getNodeExOutgoing ( ) { result = node and not outBarrier ( node , state ) }
3767
+
3764
3768
override FlowState getState ( ) { result = state }
3765
3769
3766
3770
CallContext getCallContext ( ) { result = cc }
@@ -3777,14 +3781,11 @@ module MakeImpl<InputSig Lang> {
3777
3781
}
3778
3782
3779
3783
override PathNodeImpl getASuccessorImpl ( ) {
3780
- not outBarrier ( node , state ) and
3781
- (
3782
- // an intermediate step to another intermediate node
3783
- result = this .getSuccMid ( )
3784
- or
3785
- // a final step to a sink
3786
- result = this .getSuccMid ( ) .projectToSink ( )
3787
- )
3784
+ // an intermediate step to another intermediate node
3785
+ result = this .getSuccMid ( )
3786
+ or
3787
+ // a final step to a sink
3788
+ result = this .getSuccMid ( ) .projectToSink ( )
3788
3789
}
3789
3790
3790
3791
override predicate isSource ( ) {
@@ -3935,22 +3936,22 @@ module MakeImpl<InputSig Lang> {
3935
3936
ap instanceof AccessPathNil
3936
3937
)
3937
3938
or
3938
- jumpStepEx ( mid .getNodeEx ( ) , node ) and
3939
+ jumpStepEx ( mid .getNodeExOutgoing ( ) , node ) and
3939
3940
state = mid .getState ( ) and
3940
3941
cc instanceof CallContextAny and
3941
3942
sc instanceof SummaryCtxNone and
3942
3943
t = mid .getType ( ) and
3943
3944
ap = mid .getAp ( )
3944
3945
or
3945
- additionalJumpStep ( mid .getNodeEx ( ) , node ) and
3946
+ additionalJumpStep ( mid .getNodeExOutgoing ( ) , node ) and
3946
3947
state = mid .getState ( ) and
3947
3948
cc instanceof CallContextAny and
3948
3949
sc instanceof SummaryCtxNone and
3949
3950
mid .getAp ( ) instanceof AccessPathNil and
3950
3951
t = node .getDataFlowType ( ) and
3951
3952
ap = TAccessPathNil ( )
3952
3953
or
3953
- additionalJumpStateStep ( mid .getNodeEx ( ) , mid .getState ( ) , node , state ) and
3954
+ additionalJumpStateStep ( mid .getNodeExOutgoing ( ) , mid .getState ( ) , node , state ) and
3954
3955
cc instanceof CallContextAny and
3955
3956
sc instanceof SummaryCtxNone and
3956
3957
mid .getAp ( ) instanceof AccessPathNil and
@@ -3985,7 +3986,7 @@ module MakeImpl<InputSig Lang> {
3985
3986
) {
3986
3987
ap0 = mid .getAp ( ) and
3987
3988
c = ap0 .getHead ( ) and
3988
- Stage5:: readStepCand ( mid .getNodeEx ( ) , c , node ) and
3989
+ Stage5:: readStepCand ( mid .getNodeExOutgoing ( ) , c , node ) and
3989
3990
state = mid .getState ( ) and
3990
3991
cc = mid .getCallContext ( )
3991
3992
}
@@ -3998,7 +3999,7 @@ module MakeImpl<InputSig Lang> {
3998
3999
exists ( DataFlowType contentType |
3999
4000
t0 = mid .getType ( ) and
4000
4001
ap0 = mid .getAp ( ) and
4001
- Stage5:: storeStepCand ( mid .getNodeEx ( ) , _, c , node , contentType , t ) and
4002
+ Stage5:: storeStepCand ( mid .getNodeExOutgoing ( ) , _, c , node , contentType , t ) and
4002
4003
state = mid .getState ( ) and
4003
4004
cc = mid .getCallContext ( ) and
4004
4005
compatibleTypes ( t0 , contentType )
@@ -4016,7 +4017,8 @@ module MakeImpl<InputSig Lang> {
4016
4017
not outBarrier ( retNode , state ) and
4017
4018
innercc = mid .getCallContext ( ) and
4018
4019
innercc instanceof CallContextNoCall and
4019
- apa = mid .getAp ( ) .getApprox ( )
4020
+ apa = mid .getAp ( ) .getApprox ( ) and
4021
+ not outBarrier ( retNode , state )
4020
4022
)
4021
4023
}
4022
4024
@@ -4137,7 +4139,8 @@ module MakeImpl<InputSig Lang> {
4137
4139
pathNode ( _, ret , state , cc , sc , t , ap , _) and
4138
4140
kind = ret .getKind ( ) and
4139
4141
apa = ap .getApprox ( ) and
4140
- parameterFlowThroughAllowed ( sc .getParamNode ( ) , kind )
4142
+ parameterFlowThroughAllowed ( sc .getParamNode ( ) , kind ) and
4143
+ not outBarrier ( ret , state )
4141
4144
)
4142
4145
}
4143
4146
0 commit comments