Java/Shared: Rename 'joinStep0' to 'joinStep'.

This commit is contained in:
Mathias Vorreiter Pedersen
2024-03-20 14:40:16 +00:00
parent 6a65c46b2e
commit ebac171b2b
3 changed files with 4 additions and 4 deletions

View File

@@ -75,7 +75,7 @@ private module Input implements TypeFlowInput<J::Location> {
* Holds if data can flow from `n1` to `n2` in one step, and `n1` is not
* necessarily functionally determined by `n2`.
*/
predicate joinStep0(TypeFlowNode n1, TypeFlowNode n2) {
predicate joinStep(TypeFlowNode n1, TypeFlowNode n2) {
n2.asExpr().(ChooseExpr).getAResultExpr() = n1.asExpr()
or
exists(Field f, Expr e |
@@ -134,7 +134,7 @@ private module Input implements TypeFlowInput<J::Location> {
not exists(decl.getInit())
)
or
forex(TypeFlowNode mid | joinStep0(mid, n) | Make<J::Location, Input>::isNull(mid)) and
forex(TypeFlowNode mid | joinStep(mid, n) | Make<J::Location, Input>::isNull(mid)) and
// Fields that are never assigned a non-null value are probably set by
// reflection and are thus not always null.
not exists(n.asField())

View File

@@ -31,7 +31,7 @@ signature module TypeFlowInput<LocationSig Location> {
* Holds if data can flow from `n1` to `n2` in one step, and `n1` is not
* necessarily functionally determined by `n2`.
*/
predicate joinStep0(TypeFlowNode n1, TypeFlowNode n2);
predicate joinStep(TypeFlowNode n1, TypeFlowNode n2);
/**
* Holds if data can flow from `n1` to `n2` in one step, and `n1` is

View File

@@ -16,7 +16,7 @@ module TypeFlow<LocationSig Location, TypeFlowInput<Location> I> {
* Holds if data can flow from `n1` to `n2` in one step, `n1` is not necessarily
* functionally determined by `n2`, and `n1` might take a non-null value.
*/
predicate joinStep(TypeFlowNode n1, TypeFlowNode n2) { joinStep0(n1, n2) and not isNull(n1) }
predicate joinStep(TypeFlowNode n1, TypeFlowNode n2) { I::joinStep(n1, n2) and not isNull(n1) }
private predicate anyStep(TypeFlowNode n1, TypeFlowNode n2) { joinStep(n1, n2) or step(n1, n2) }