blob: 2b49e3c3d38603ac8a875a2f60f60eba5db45af6 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
|
package kanga.kanga2mips;
public class KangaSym {
public enum Type { HALLOC, BINOP, SIMPLE };
public enum SimpleType { REG, INT, LABEL };
public Type e_type;
public SimpleType s_type;
public int value; // for integer simple type
public int binop; // Binary operator
public String name; // for register or label name
public String name2; // for second oprand
public KangaSym oprand2; // for second oprand
public KangaSym(Type t) {
e_type = t;
}
public KangaSym(Type t, SimpleType s) {
e_type = t;
s_type = s;
}
}
|