edits
[satune.git] / src / AST / boolean.c
1 #include "boolean.h"
2
3 Boolean* allocBoolean(VarType t) {
4         BooleanVar* tmp=(BooleanVar *) ourmalloc(sizeof (BooleanVar));
5         GETBOOLEANTYPE(tmp)=BOOLEANVAR;
6         tmp->vtype=t;
7         return & tmp->base;
8 }
9
10 Boolean* allocBooleanOrder(Order* order, uint64_t first, uint64_t second) {
11         BooleanOrder* tmp=(BooleanOrder *) ourmalloc(sizeof (BooleanOrder));
12         GETBOOLEANTYPE(tmp)=ORDERCONST;
13         tmp->order=order;
14         tmp->first=first;
15         tmp->second=second;
16         return & tmp -> base;
17 }
18
19 void deleteBoolean(Boolean * This) {
20         ourfree(This);
21 }