private Expr compare(BinaryOperation op, Variable value) { Expr expr = Expr.binary(op, Expr.var(value.getIndex()), Expr.constant(0)); expr.setLocation(currentLocation); return expr; }
private void assign(Expr source, Variable target) { AssignmentStatement stmt = Statement.assign(Expr.var(target.getIndex()), source); stmt.setLocation(currentLocation); stmt.getDebugNames().addAll(target.getDebugNames()); statements.add(stmt); }