Keeping the type of Boolean/Element struct, as well as keeping backward edges for...
[satune.git] / src / AST / element.h
1 #ifndef ELEMENT_H
2 #define ELEMENT_H
3 #include "classlist.h"
4 #include "mymemory.h"
5 #include "ops.h"
6 #include "structs.h"
7 #include "structtype.h"
8
9 #define GETELEMENTTYPE(o) (((Element*)o)->type)
10
11 struct Element {
12         Struct stype;
13         ElementType type;
14 };
15
16 struct ElementSet {
17         Element base;
18         Set * set;
19         ElementEncoding * encoding;
20 };
21
22 struct ElementFunction {
23         Element base;
24         Function * function;
25         VectorElement* Elements;
26         Boolean * overflowstatus;
27 };
28
29 Element * allocElementSet(Set *s);
30 Element* allocElementFunction(Function * function, Element ** array, uint numArrays, Boolean * overflowstatus);
31 void deleteElement(Element *This);
32 #endif