@@ -180,12 +180,16 @@ private class ArrayContent extends Content, TArrayContent {
180180 override Type getType ( ) { none ( ) }
181181}
182182
183- /**
184- * Holds if data can flow from `node1` to `node2` via an assignment to `f`.
185- * Thus, `node2` references an object with a field `f` that contains the
186- * value of `node1`.
187- */
188- predicate storeStep ( Node node1 , Content f , PostUpdateNode node2 ) {
183+ private predicate storeStepNoChi ( Node node1 , Content f , PostUpdateNode node2 ) {
184+ exists ( FieldAddressInstruction fa , StoreInstruction store |
185+ store = node2 .asInstruction ( ) and
186+ store .getDestinationAddress ( ) = fa and
187+ store .getSourceValue ( ) = node1 .asInstruction ( ) and
188+ f .( FieldContent ) .getField ( ) = fa .getField ( )
189+ )
190+ }
191+
192+ private predicate storeStepChi ( Node node1 , Content f , PostUpdateNode node2 ) {
189193 exists ( FieldAddressInstruction fa , StoreInstruction store |
190194 node1 .asInstruction ( ) = store and
191195 store .getDestinationAddress ( ) = fa and
@@ -194,6 +198,16 @@ predicate storeStep(Node node1, Content f, PostUpdateNode node2) {
194198 )
195199}
196200
201+ /**
202+ * Holds if data can flow from `node1` to `node2` via an assignment to `f`.
203+ * Thus, `node2` references an object with a field `f` that contains the
204+ * value of `node1`.
205+ */
206+ predicate storeStep ( Node node1 , Content f , PostUpdateNode node2 ) {
207+ storeStepNoChi ( node1 , f , node2 ) or
208+ storeStepChi ( node1 , f , node2 )
209+ }
210+
197211/**
198212 * Holds if data can flow from `node1` to `node2` via a read of `f`.
199213 * Thus, `node1` references an object with a field `f` whose value ends up in
0 commit comments