3 * Author: Kaustuv Chaudhuri <kaustuv+@cs.cmu.edu>
4 * Modified: Alex Vaynberg <alv@andrew.cmu.edu>
5 * Modified: Frank Pfenning <fp@cs.cmu.edu>
6 * Modified: Joshua Wise <jwise>
7 * Modified: Chris Lu <czl>
12 datatype binop = ADD | SUB | MUL | DIV | MOD | LSH | RSH | LOGOR | LOGAND | BITOR | BITAND | BITXOR | NEQ | EQ | LT | GT | LE | GE | BE
13 datatype unop = NEG | BITNOT | BANG
20 | ARG of Blarg (* I am j4cbo *)
21 | BINOP of binop * exp * exp
23 | CALL of Ast.ident * exp list
26 | COND of exp * exp * exp
27 | STMVAR of stm list * exp
33 | LABEL of Label.label
34 | JUMPIFN of exp * Label.label
37 FUNCTION of Ast.ident * stm list
39 type program = func list
42 structure Tree :> TREE =
44 datatype binop = ADD | SUB | MUL | DIV | MOD | LSH | RSH | LOGOR | LOGAND | BITOR | BITAND | BITXOR | NEQ | EQ | LT | GT | LE | GE | BE
45 datatype unop = NEG | BITNOT | BANG
52 | ARG of Blarg (* I am j4cbo *)
53 | BINOP of binop * exp * exp
55 | CALL of Ast.ident * exp list
58 | COND of exp * exp * exp
59 | STMVAR of stm list * exp
65 | LABEL of Label.label
66 | JUMPIFN of exp * Label.label
69 FUNCTION of Ast.ident * stm list
71 type program = func list