a6174c36094ea7e23fb510bfc65036953917c743
1 #ifndef OBERON_INTERNALS_H
2 #define OBERON_INTERNALS_H
21 struct oberon_scope_t
22 {
29 };
31 enum
32 {
33 OBERON_TYPE_VOID,
34 OBERON_TYPE_INTEGER,
35 OBERON_TYPE_BOOLEAN,
36 OBERON_TYPE_PROCEDURE,
37 OBERON_TYPE_ARRAY,
38 OBERON_TYPE_RECORD,
39 OBERON_TYPE_POINTER,
40 OBERON_TYPE_REAL
41 };
43 struct oberon_type_t
44 {
57 };
59 enum
60 {
61 OBERON_CLASS_VAR,
62 OBERON_CLASS_TYPE,
63 OBERON_CLASS_PROC,
64 OBERON_CLASS_PARAM,
65 OBERON_CLASS_VAR_PARAM,
66 OBERON_CLASS_CONST,
67 OBERON_CLASS_FIELD,
68 OBERON_CLASS_MODULE
69 };
74 struct oberon_object_t
75 {
90 GenerateFuncCallback genfunc;
91 GenerateProcCallback genproc;
101 };
103 struct oberon_module_t
104 {
113 };
117 struct oberon_context_t
118 {
119 /*** SCANER DATA ***/
128 /*** END SCANER DATA ***/
130 /*** PARSER DATA ***/
133 /*** END PARSER DATA ***/
142 ModuleImportCallback import_module;
144 };
146 enum
147 {
148 MODE_VAR,
149 MODE_INTEGER,
150 MODE_BOOLEAN,
151 MODE_CALL,
152 MODE_INDEX,
153 MODE_FIELD,
154 MODE_DEREF,
155 MODE_NIL,
156 MODE_NEW,
157 MODE_REAL
158 };
160 enum
161 {
162 OP_UNARY_MINUS,
163 OP_BITWISE_NOT,
164 OP_LOGIC_NOT,
165 OP_ABS,
167 OP_ADD,
168 OP_SUB,
169 OP_MUL,
170 OP_DIV,
171 OP_MOD,
172 OP_BITWISE_AND,
173 OP_BITWISE_XOR,
174 OP_BITWISE_OR,
175 OP_LOGIC_AND,
176 OP_LOGIC_OR,
178 OP_EQ,
179 OP_NEQ,
180 OP_LSS,
181 OP_LEQ,
182 OP_GRT,
183 OP_GEQ
184 };
186 struct oberon_item_t
187 {
203 };
205 struct oberon_oper_t
206 {
215 };
217 union oberon_expr_t
218 {
224 };
226 oberon_item_t item;
227 oberon_oper_t oper;
228 };