Skip to content

Commit ca7d560

Browse files
committed
ControlFlow: Rename getAPhiInput to getAnInput.
1 parent 64caae5 commit ca7d560

File tree

3 files changed

+9
-3
lines changed

3 files changed

+9
-3
lines changed

java/ql/lib/semmle/code/java/dataflow/SSA.qll

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -336,6 +336,9 @@ class SsaPhiNode extends SsaVariable instanceof PhiNode {
336336
/** Gets an input to the phi node defining the SSA variable. */
337337
SsaVariable getAPhiInput() { this.hasInputFromBlock(result, _) }
338338

339+
/** Gets an input to the phi node defining the SSA variable. */
340+
SsaVariable getAnInput() { this.hasInputFromBlock(result, _) }
341+
339342
/** Holds if `inp` is an input to the phi node along the edge originating in `bb`. */
340343
predicate hasInputFromBlock(SsaVariable inp, BasicBlock bb) {
341344
phiHasInputFromBlock(this, inp, bb)

java/ql/lib/semmle/code/java/dataflow/internal/BaseSSA.qll

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -366,6 +366,9 @@ class BaseSsaPhiNode extends BaseSsaVariable instanceof Impl::PhiNode {
366366
/** Gets an input to the phi node defining the SSA variable. */
367367
BaseSsaVariable getAPhiInput() { this.hasInputFromBlock(result, _) }
368368

369+
/** Gets an input to the phi node defining the SSA variable. */
370+
BaseSsaVariable getAnInput() { this.hasInputFromBlock(result, _) }
371+
369372
/** Holds if `inp` is an input to the phi node along the edge originating in `bb`. */
370373
predicate hasInputFromBlock(BaseSsaVariable inp, BasicBlock bb) {
371374
phiHasInputFromBlock(this, inp, bb)

shared/controlflow/codeql/controlflow/ControlFlow.qll

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -64,7 +64,7 @@ signature module InputSig<LocationSig Location, TypSig ControlFlowNode, TypSig B
6464
/** Holds if `inp` is an input to the phi node along the edge originating in `bb`. */
6565
predicate hasInputFromBlock(SsaDefinition inp, BasicBlock bb);
6666

67-
SsaDefinition getAPhiInput();
67+
SsaDefinition getAnInput();
6868
}
6969

7070
class SsaUncertainDefinition extends SsaDefinition {
@@ -663,8 +663,8 @@ module Make<
663663
or
664664
exists(SsaPhiNode phi |
665665
phi.definesAt(var, loopEntry, _) and
666-
phi.getAPhiInput+() = def and
667-
def.(SsaPhiNode).getAPhiInput*() = phi
666+
phi.getAnInput+() = def and
667+
def.(SsaPhiNode).getAnInput*() = phi
668668
)
669669
)
670670
}

0 commit comments

Comments
 (0)