public override void visit(Complement comp) { comp.expr.accept(this); emit_lw("t1", 12, "a0"); emit_not("t1", "t1"); emit_sw("t1", 12, "a0"); }
public override void visit(Complement cmpl) { cmpl.expr.accept(this); cmpl.type = Constants.INTEGER; if (cmpl.expr.type != Constants.INTEGER) { error(cmpl, "RHS of expression must evaluate to type Int"); cmpl.type = Constants.OBJECT; } }
public override void visit(Complement complement) { for (int i = 0; i < depth * 2; i++) { sw.Write(" "); } depth++; sw.WriteLine("_complement : " + complement.type); complement.expr.accept(this); depth--; }
public abstract void visit(Complement complement);