Fix warnings, merge, and check my code in
[satune.git] / src / AST / ops.h
1 #ifndef OPS_H
2 #define OPS_H
3 enum LogicOp {L_AND, L_OR, L_NOT, L_XOR, L_IMPLIES};
4 typedef enum LogicOp LogicOp;
5
6 enum ArithOp {ADD, SUB};
7 typedef enum ArithOp ArithOp;
8
9 enum CompOp {EQUALS};
10 typedef enum CompOp CompOp;
11
12 enum OrderType {PARTIAL, TOTAL};
13 typedef enum OrderType OrderType;
14
15 /**
16  *    FLAGFORCESOVERFLOW forces the operation to overflow if the boolean flag is true
17  *  OVERFLOWSETSFLAG -- sets the flag if the operation overflows
18  *  FLAGIFFOVERFLOW -- flag is set iff the operation overflows
19  *  IGNORE -- doesn't constrain output if the result cannot be represented
20  *  WRAPAROUND -- wraps around like stand integer arithmetic
21  *  NOOVERFLOW -- client has ensured that overflow is impossible
22  */
23 enum OverFlowBehavior {IGNORE, WRAPAROUND, FLAGFORCESOVERFLOW, OVERFLOWSETSFLAG, FLAGIFFOVERFLOW, NOOVERFLOW};
24 typedef enum OverFlowBehavior OverFlowBehavior;
25
26 enum BooleanType {ORDERCONST, BOOLEANVAR, LOGICOP, COMPARE};
27 typedef enum BooleanType BooleanType;
28
29 enum FunctionType {TABLEFUNC, OPERATORFUNC};
30 typedef enum FunctionType FunctionType;
31 #endif