File tree Expand file tree Collapse file tree
cpp/ql/lib/semmle/code/cpp/ir/dataflow/internal Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -1396,13 +1396,16 @@ private class PhiCycle extends PhiCycleEquivalence::EquivalenceClass {
13961396
13971397 predicate hasPhiNode ( PhiNode phi ) { this .getAPhiNode ( ) = phi }
13981398
1399+ pragma [ nomagic]
1400+ Definition getAnInput ( ) {
1401+ result = this .getAPhiNode ( ) .getAnInput ( ) and not this .hasPhiNode ( result )
1402+ }
1403+
13991404 string toString ( ) { result = strictconcat ( this .getAPhiNode ( ) .toString ( ) , ", " ) }
14001405
14011406 predicate isCertain ( ) {
14021407 // A phi cycle is certain if all of the inputs into the phi cycle is certain.
1403- forex ( PhiNode phi | phi = this .getAPhiNode ( ) |
1404- forall ( PhiNode inp | phi .getAnInput ( ) = inp and not this .hasPhiNode ( inp ) | inp .isCertain ( ) )
1405- )
1408+ forex ( Definition inp | inp = this .getAnInput ( ) | inp .isCertain ( ) )
14061409 }
14071410}
14081411
You can’t perform that action at this time.
0 commit comments