File tree Expand file tree Collapse file tree 2 files changed +8
-8
lines changed
java/ql/lib/semmle/code/java/dataflow Expand file tree Collapse file tree 2 files changed +8
-8
lines changed Original file line number Diff line number Diff line change @@ -228,9 +228,10 @@ class SsaImplicitUpdate extends SsaUpdate {
228
228
}
229
229
230
230
private predicate hasExplicitQualifierUpdate ( ) {
231
- exists ( SsaExplicitUpdate qdef , BasicBlock bb , int i |
231
+ exists ( SsaUpdate qdef , BasicBlock bb , int i |
232
232
qdef .definesAt ( this .getSourceVariable ( ) .getQualifier ( ) , bb , i ) and
233
- this .definesAt ( _, bb , i )
233
+ this .definesAt ( _, bb , i ) and
234
+ not qdef instanceof SsaUncertainImplicitUpdate
234
235
)
235
236
}
236
237
Original file line number Diff line number Diff line change @@ -44,7 +44,7 @@ private module TrackedVariablesImpl {
44
44
}
45
45
46
46
/** Holds if `f` is accessed more than once or inside a loop. */
47
- predicate multiAccessed ( SsaSourceField f ) { loopAccessed ( f ) or 1 < numberOfAccesses ( f ) }
47
+ private predicate multiAccessed ( SsaSourceField f ) { loopAccessed ( f ) or 1 < numberOfAccesses ( f ) }
48
48
49
49
/**
50
50
* Holds if `f` is a field that is interesting as a basis for SSA.
@@ -619,13 +619,12 @@ private module Cached {
619
619
useReaches ( use , mid , sameVarMid ) and
620
620
DataFlowIntegration:: localFlowStep ( _, mid , node , _)
621
621
|
622
- // flow into phi input node
623
- mid instanceof DataFlowIntegration:: SsaInputNode and
624
- sameVar = false
625
- or
626
- // flow into definition
627
622
exists ( Impl:: DefinitionExt def |
623
+ // flow into definition
628
624
def = mid .( DataFlowIntegration:: SsaDefinitionExtNode ) .getDefinitionExt ( )
625
+ or
626
+ // flow into phi input node
627
+ def = mid .( DataFlowIntegration:: SsaInputNode ) .getDefinitionExt ( )
629
628
|
630
629
if def instanceof Impl:: PhiReadNode then sameVar = sameVarMid else sameVar = false
631
630
)
You can’t perform that action at this time.
0 commit comments