Mass rename L/RValue -> VarWrite/Read

This commit is contained in:
Chris Smowton
2023-10-24 10:58:29 +01:00
committed by GitHub
parent 59a49eef0b
commit ac38d4c9c6
36 changed files with 81 additions and 81 deletions

View File

@@ -15,10 +15,10 @@ private Expr exprWithIntValue(int i) {
/**
* An expression for which the predicate `integerGuard` is relevant.
* This includes `RValue` and `MethodCall`.
* This includes `VarRead` and `MethodCall`.
*/
class IntComparableExpr extends Expr {
IntComparableExpr() { this instanceof RValue or this instanceof MethodCall }
IntComparableExpr() { this instanceof VarRead or this instanceof MethodCall }
/** Gets an integer that is directly assigned to the expression in case of a variable; or zero. */
int relevantInt() {
@@ -132,7 +132,7 @@ Expr integerGuard(IntComparableExpr e, boolean branch, int k, boolean is_k) {
* If `branch_with_lower_bound_k` is true then `result` is equivalent to `k <= x`
* and if it is false then `result` is equivalent to `k > x`.
*/
Expr intBoundGuard(RValue x, boolean branch_with_lower_bound_k, int k) {
Expr intBoundGuard(VarRead x, boolean branch_with_lower_bound_k, int k) {
exists(ComparisonExpr comp, ConstantIntegerExpr c, int val |
comp = result and
comp.hasOperands(x, c) and