70 void *null_visitor_c::visit(class_name_c *symbol) {return NULL;} |
70 void *null_visitor_c::visit(class_name_c *symbol) {return NULL;} |
71 |
71 |
72 #define SYM_REF0(class_name_c) \ |
72 #define SYM_REF0(class_name_c) \ |
73 void *null_visitor_c::visit(class_name_c *symbol) {return NULL;} |
73 void *null_visitor_c::visit(class_name_c *symbol) {return NULL;} |
74 |
74 |
|
75 #define SYM_REF1(class_name_c, ref1) \ |
|
76 void *null_visitor_c::visit(class_name_c *symbol) {return NULL;} |
|
77 |
75 #define SYM_REF2(class_name_c, ref1, ref2) \ |
78 #define SYM_REF2(class_name_c, ref1, ref2) \ |
76 void *null_visitor_c::visit(class_name_c *symbol) {return NULL;} |
79 void *null_visitor_c::visit(class_name_c *symbol) {return NULL;} |
77 |
80 |
|
81 #define SYM_REF3(class_name_c, ref1, ref2, ref3) \ |
|
82 void *null_visitor_c::visit(class_name_c *symbol) {return NULL;} |
|
83 |
78 #define SYM_REF4(class_name_c, ref1, ref2, ref3, ref4) \ |
84 #define SYM_REF4(class_name_c, ref1, ref2, ref3, ref4) \ |
|
85 void *null_visitor_c::visit(class_name_c *symbol) {return NULL;} |
|
86 |
|
87 #define SYM_REF5(class_name_c, ref1, ref2, ref3, ref4, ref5) \ |
79 void *null_visitor_c::visit(class_name_c *symbol) {return NULL;} |
88 void *null_visitor_c::visit(class_name_c *symbol) {return NULL;} |
80 |
89 |
81 #define SYM_REF6(class_name_c, ref1, ref2, ref3, ref4, ref5, ref6) \ |
90 #define SYM_REF6(class_name_c, ref1, ref2, ref3, ref4, ref5, ref6) \ |
82 void *null_visitor_c::visit(class_name_c *symbol) {return NULL;} |
91 void *null_visitor_c::visit(class_name_c *symbol) {return NULL;} |
83 |
92 |
121 void *iterator_visitor_c::visit(class_name_c *symbol) {return NULL;} |
133 void *iterator_visitor_c::visit(class_name_c *symbol) {return NULL;} |
122 |
134 |
123 #define SYM_REF0(class_name_c) \ |
135 #define SYM_REF0(class_name_c) \ |
124 void *iterator_visitor_c::visit(class_name_c *symbol) {return NULL;} |
136 void *iterator_visitor_c::visit(class_name_c *symbol) {return NULL;} |
125 |
137 |
|
138 #define SYM_REF1(class_name_c, ref1) \ |
|
139 void *iterator_visitor_c::visit(class_name_c *symbol) { \ |
|
140 if (symbol->ref1!=NULL) symbol->ref1->accept(*this); \ |
|
141 return NULL; \ |
|
142 } |
|
143 |
126 #define SYM_REF2(class_name_c, ref1, ref2) \ |
144 #define SYM_REF2(class_name_c, ref1, ref2) \ |
127 void *iterator_visitor_c::visit(class_name_c *symbol) { \ |
145 void *iterator_visitor_c::visit(class_name_c *symbol) { \ |
128 if (symbol->ref1!=NULL) symbol->ref1->accept(*this); \ |
146 if (symbol->ref1!=NULL) symbol->ref1->accept(*this); \ |
129 if (symbol->ref2!=NULL) symbol->ref2->accept(*this); \ |
147 if (symbol->ref2!=NULL) symbol->ref2->accept(*this); \ |
|
148 return NULL; \ |
|
149 } |
|
150 |
|
151 #define SYM_REF3(class_name_c, ref1, ref2, ref3) \ |
|
152 void *iterator_visitor_c::visit(class_name_c *symbol) { \ |
|
153 if (symbol->ref1) symbol->ref1->accept(*this); \ |
|
154 if (symbol->ref2) symbol->ref2->accept(*this); \ |
|
155 if (symbol->ref3) symbol->ref3->accept(*this); \ |
130 return NULL; \ |
156 return NULL; \ |
131 } |
157 } |
132 |
158 |
133 #define SYM_REF4(class_name_c, ref1, ref2, ref3, ref4) \ |
159 #define SYM_REF4(class_name_c, ref1, ref2, ref3, ref4) \ |
134 void *iterator_visitor_c::visit(class_name_c *symbol) { \ |
160 void *iterator_visitor_c::visit(class_name_c *symbol) { \ |
137 if (symbol->ref3) symbol->ref3->accept(*this); \ |
163 if (symbol->ref3) symbol->ref3->accept(*this); \ |
138 if (symbol->ref4) symbol->ref4->accept(*this); \ |
164 if (symbol->ref4) symbol->ref4->accept(*this); \ |
139 return NULL; \ |
165 return NULL; \ |
140 } |
166 } |
141 |
167 |
|
168 #define SYM_REF5(class_name_c, ref1, ref2, ref3, ref4, ref5) \ |
|
169 void *iterator_visitor_c::visit(class_name_c *symbol) { \ |
|
170 if (symbol->ref1) symbol->ref1->accept(*this); \ |
|
171 if (symbol->ref2) symbol->ref2->accept(*this); \ |
|
172 if (symbol->ref3) symbol->ref3->accept(*this); \ |
|
173 if (symbol->ref4) symbol->ref4->accept(*this); \ |
|
174 if (symbol->ref5) symbol->ref5->accept(*this); \ |
|
175 return NULL; \ |
|
176 } |
142 |
177 |
143 #define SYM_REF6(class_name_c, ref1, ref2, ref3, ref4, ref5, ref6) \ |
178 #define SYM_REF6(class_name_c, ref1, ref2, ref3, ref4, ref5, ref6) \ |
144 void *iterator_visitor_c::visit(class_name_c *symbol) { \ |
179 void *iterator_visitor_c::visit(class_name_c *symbol) { \ |
145 if (symbol->ref1) symbol->ref1->accept(*this); \ |
180 if (symbol->ref1) symbol->ref1->accept(*this); \ |
146 if (symbol->ref2) symbol->ref2->accept(*this); \ |
181 if (symbol->ref2) symbol->ref2->accept(*this); \ |
197 void *search_visitor_c::visit(class_name_c *symbol) {return NULL;} |
235 void *search_visitor_c::visit(class_name_c *symbol) {return NULL;} |
198 |
236 |
199 #define SYM_REF0(class_name_c) \ |
237 #define SYM_REF0(class_name_c) \ |
200 void *search_visitor_c::visit(class_name_c *symbol) {return NULL;} |
238 void *search_visitor_c::visit(class_name_c *symbol) {return NULL;} |
201 |
239 |
|
240 #define SYM_REF1(class_name_c, ref1) \ |
|
241 void *search_visitor_c::visit(class_name_c *symbol) { \ |
|
242 if (symbol->ref1) return symbol->ref1->accept(*this); \ |
|
243 return NULL; \ |
|
244 } |
|
245 |
202 #define SYM_REF2(class_name_c, ref1, ref2) \ |
246 #define SYM_REF2(class_name_c, ref1, ref2) \ |
203 void *search_visitor_c::visit(class_name_c *symbol) { \ |
247 void *search_visitor_c::visit(class_name_c *symbol) { \ |
204 void *res = NULL; \ |
248 void *res = NULL; \ |
205 if (symbol->ref1) res = symbol->ref1->accept(*this); \ |
249 if (symbol->ref1) res = symbol->ref1->accept(*this); \ |
206 if (res != NULL) return res; \ |
250 if (res != NULL) return res; \ |
207 if (symbol->ref2) return symbol->ref2->accept(*this); \ |
251 if (symbol->ref2) return symbol->ref2->accept(*this); \ |
208 return NULL; \ |
252 return NULL; \ |
209 } |
253 } |
210 |
254 |
|
255 #define SYM_REF3(class_name_c, ref1, ref2, ref3) \ |
|
256 void *search_visitor_c::visit(class_name_c *symbol) { \ |
|
257 void *res = NULL; \ |
|
258 if (symbol->ref1) res = symbol->ref1->accept(*this); \ |
|
259 if (res != NULL) return res; \ |
|
260 if (symbol->ref2) res = symbol->ref2->accept(*this); \ |
|
261 if (res != NULL) return res; \ |
|
262 if (symbol->ref3) return symbol->ref3->accept(*this); \ |
|
263 return NULL; \ |
|
264 } |
|
265 |
211 #define SYM_REF4(class_name_c, ref1, ref2, ref3, ref4) \ |
266 #define SYM_REF4(class_name_c, ref1, ref2, ref3, ref4) \ |
212 void *search_visitor_c::visit(class_name_c *symbol) { \ |
267 void *search_visitor_c::visit(class_name_c *symbol) { \ |
213 void *res = NULL; \ |
268 void *res = NULL; \ |
214 if (symbol->ref1) res = symbol->ref1->accept(*this); \ |
269 if (symbol->ref1) res = symbol->ref1->accept(*this); \ |
215 if (res != NULL) return res; \ |
270 if (res != NULL) return res; \ |
219 if (res != NULL) return res; \ |
274 if (res != NULL) return res; \ |
220 if (symbol->ref4) return symbol->ref4->accept(*this); \ |
275 if (symbol->ref4) return symbol->ref4->accept(*this); \ |
221 return NULL; \ |
276 return NULL; \ |
222 } |
277 } |
223 |
278 |
|
279 #define SYM_REF5(class_name_c, ref1, ref2, ref3, ref4, ref5) \ |
|
280 void *search_visitor_c::visit(class_name_c *symbol) { \ |
|
281 void *res = NULL; \ |
|
282 if (symbol->ref1) res = symbol->ref1->accept(*this); \ |
|
283 if (res != NULL) return res; \ |
|
284 if (symbol->ref2) res = symbol->ref2->accept(*this); \ |
|
285 if (res != NULL) return res; \ |
|
286 if (symbol->ref3) res = symbol->ref3->accept(*this); \ |
|
287 if (res != NULL) return res; \ |
|
288 if (symbol->ref4) res = symbol->ref4->accept(*this); \ |
|
289 if (res != NULL) return res; \ |
|
290 if (symbol->ref5) return symbol->ref5->accept(*this); \ |
|
291 return NULL; \ |
|
292 } |
224 |
293 |
225 #define SYM_REF6(class_name_c, ref1, ref2, ref3, ref4, ref5, ref6) \ |
294 #define SYM_REF6(class_name_c, ref1, ref2, ref3, ref4, ref5, ref6) \ |
226 void *search_visitor_c::visit(class_name_c *symbol) { \ |
295 void *search_visitor_c::visit(class_name_c *symbol) { \ |
227 void *res = NULL; \ |
296 void *res = NULL; \ |
228 if (symbol->ref1) res = symbol->ref1->accept(*this); \ |
297 if (symbol->ref1) res = symbol->ref1->accept(*this); \ |