neo: Correct the documentation of neo.nit according to PR #734.
[nit.git] / c_src / parser_prod.sep.1.c
1 #include "parser_prod.sep.0.h"
2 /* method parser_prod#AModule#init_amodule for (self: AModule, nullable AModuledecl, Collection[Object], Collection[Object], Collection[Object]) */
3 void parser_prod__AModule__init_amodule(val* self, val* p0, val* p1, val* p2, val* p3) {
4 val* var_n_moduledecl /* var n_moduledecl: nullable AModuledecl */;
5 val* var_n_imports /* var n_imports: Collection[Object] */;
6 val* var_n_extern_code_blocks /* var n_extern_code_blocks: Collection[Object] */;
7 val* var_n_classdefs /* var n_classdefs: Collection[Object] */;
8 val* var /* : null */;
9 short int var1 /* : Bool */;
10 short int var2 /* : Bool */;
11 val* var_other /* var other: nullable Object */;
12 short int var4 /* : Bool */;
13 short int var5 /* : Bool */;
14 short int var6 /* : Bool */;
15 val* var8 /* : ANodes[AImport] */;
16 val* var10 /* : ANodes[AImport] */;
17 val* var11 /* : ANodes[AExternCodeBlock] */;
18 val* var13 /* : ANodes[AExternCodeBlock] */;
19 val* var14 /* : ANodes[AClassdef] */;
20 val* var16 /* : ANodes[AClassdef] */;
21 var_n_moduledecl = p0;
22 var_n_imports = p1;
23 var_n_extern_code_blocks = p2;
24 var_n_classdefs = p3;
25 self->attrs[COLOR_parser_nodes__AModule___n_moduledecl].val = var_n_moduledecl; /* _n_moduledecl on <self:AModule> */
26 var = NULL;
27 if (var_n_moduledecl == NULL) {
28 var1 = 0; /* is null */
29 } else {
30 var1 = 1; /* arg is null and recv is not */
31 }
32 if (0) {
33 { /* Inline kernel#Object#!= (var_n_moduledecl,var) on <var_n_moduledecl:nullable AModuledecl> */
34 var_other = var;
35 {
36 var5 = ((short int (*)(val*, val*))(var_n_moduledecl->class->vft[COLOR_kernel__Object___61d_61d]))(var_n_moduledecl, var_other) /* == on <var_n_moduledecl:nullable AModuledecl(AModuledecl)>*/;
37 var4 = var5;
38 }
39 var6 = !var4;
40 var2 = var6;
41 goto RET_LABEL3;
42 RET_LABEL3:(void)0;
43 }
44 var1 = var2;
45 }
46 if (var1){
47 {
48 { /* Inline parser_nodes#ANode#parent= (var_n_moduledecl,self) on <var_n_moduledecl:nullable AModuledecl(AModuledecl)> */
49 var_n_moduledecl->attrs[COLOR_parser_nodes__ANode___parent].val = self; /* _parent on <var_n_moduledecl:nullable AModuledecl(AModuledecl)> */
50 RET_LABEL7:(void)0;
51 }
52 }
53 } else {
54 }
55 {
56 { /* Inline parser_nodes#AModule#n_imports (self) on <self:AModule> */
57 var10 = self->attrs[COLOR_parser_nodes__AModule___n_imports].val; /* _n_imports on <self:AModule> */
58 if (unlikely(var10 == NULL)) {
59 PRINT_ERROR("Runtime error: %s", "Uninitialized attribute _n_imports");
60 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_nodes.nit", 697);
61 show_backtrace(1);
62 }
63 var8 = var10;
64 RET_LABEL9:(void)0;
65 }
66 }
67 {
68 parser_nodes__ANodes__unsafe_add_all(var8, var_n_imports); /* Direct call parser_nodes#ANodes#unsafe_add_all on <var8:ANodes[AImport]>*/
69 }
70 {
71 { /* Inline parser_nodes#AModule#n_extern_code_blocks (self) on <self:AModule> */
72 var13 = self->attrs[COLOR_parser_nodes__AModule___n_extern_code_blocks].val; /* _n_extern_code_blocks on <self:AModule> */
73 if (unlikely(var13 == NULL)) {
74 PRINT_ERROR("Runtime error: %s", "Uninitialized attribute _n_extern_code_blocks");
75 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_nodes.nit", 698);
76 show_backtrace(1);
77 }
78 var11 = var13;
79 RET_LABEL12:(void)0;
80 }
81 }
82 {
83 parser_nodes__ANodes__unsafe_add_all(var11, var_n_extern_code_blocks); /* Direct call parser_nodes#ANodes#unsafe_add_all on <var11:ANodes[AExternCodeBlock]>*/
84 }
85 {
86 { /* Inline parser_nodes#AModule#n_classdefs (self) on <self:AModule> */
87 var16 = self->attrs[COLOR_parser_nodes__AModule___n_classdefs].val; /* _n_classdefs on <self:AModule> */
88 if (unlikely(var16 == NULL)) {
89 PRINT_ERROR("Runtime error: %s", "Uninitialized attribute _n_classdefs");
90 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_nodes.nit", 699);
91 show_backtrace(1);
92 }
93 var14 = var16;
94 RET_LABEL15:(void)0;
95 }
96 }
97 {
98 parser_nodes__ANodes__unsafe_add_all(var14, var_n_classdefs); /* Direct call parser_nodes#ANodes#unsafe_add_all on <var14:ANodes[AClassdef]>*/
99 }
100 RET_LABEL:;
101 }
102 /* method parser_prod#AModule#init_amodule for (self: Object, nullable AModuledecl, Collection[Object], Collection[Object], Collection[Object]) */
103 void VIRTUAL_parser_prod__AModule__init_amodule(val* self, val* p0, val* p1, val* p2, val* p3) {
104 parser_prod__AModule__init_amodule(self, p0, p1, p2, p3); /* Direct call parser_prod#AModule#init_amodule on <self:Object(AModule)>*/
105 RET_LABEL:;
106 }
107 /* method parser_prod#AModule#replace_child for (self: AModule, ANode, nullable ANode) */
108 void parser_prod__AModule__replace_child(val* self, val* p0, val* p1) {
109 val* var_old_child /* var old_child: ANode */;
110 val* var_new_child /* var new_child: nullable ANode */;
111 val* var /* : nullable AModuledecl */;
112 short int var1 /* : Bool */;
113 short int var2 /* : Bool */;
114 val* var_other /* var other: nullable Object */;
115 short int var4 /* : Bool */;
116 short int var6 /* : Bool */;
117 short int var7 /* : Bool */;
118 int cltype;
119 int idtype;
120 const char* var_class_name;
121 val* var8 /* : ANodes[AImport] */;
122 val* var10 /* : ANodes[AImport] */;
123 short int var11 /* : Bool */;
124 val* var12 /* : ANodes[AExternCodeBlock] */;
125 val* var14 /* : ANodes[AExternCodeBlock] */;
126 short int var15 /* : Bool */;
127 val* var16 /* : ANodes[AClassdef] */;
128 val* var18 /* : ANodes[AClassdef] */;
129 short int var19 /* : Bool */;
130 var_old_child = p0;
131 var_new_child = p1;
132 var = self->attrs[COLOR_parser_nodes__AModule___n_moduledecl].val; /* _n_moduledecl on <self:AModule> */
133 if (var == NULL) {
134 var1 = 0; /* <var_old_child:ANode> cannot be null */
135 } else {
136 { /* Inline kernel#Object#== (var,var_old_child) on <var:nullable AModuledecl> */
137 var_other = var_old_child;
138 {
139 { /* Inline kernel#Object#is_same_instance (var,var_other) on <var:nullable AModuledecl(AModuledecl)> */
140 var6 = var == var_other;
141 var4 = var6;
142 goto RET_LABEL5;
143 RET_LABEL5:(void)0;
144 }
145 }
146 var2 = var4;
147 goto RET_LABEL3;
148 RET_LABEL3:(void)0;
149 }
150 var1 = var2;
151 }
152 if (var1){
153 /* <var_new_child:nullable ANode> isa nullable AModuledecl */
154 cltype = type_nullable_parser_nodes__AModuledecl.color;
155 idtype = type_nullable_parser_nodes__AModuledecl.id;
156 if(var_new_child == NULL) {
157 var7 = 1;
158 } else {
159 if(cltype >= var_new_child->type->table_size) {
160 var7 = 0;
161 } else {
162 var7 = var_new_child->type->type_table[cltype] == idtype;
163 }
164 }
165 if (unlikely(!var7)) {
166 var_class_name = var_new_child == NULL ? "null" : var_new_child->type->name;
167 PRINT_ERROR("Runtime error: Cast failed. Expected `%s`, got `%s`", "nullable AModuledecl", var_class_name);
168 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 27);
169 show_backtrace(1);
170 }
171 {
172 parser_prod__AModule__n_moduledecl_61d(self, var_new_child); /* Direct call parser_prod#AModule#n_moduledecl= on <self:AModule>*/
173 }
174 goto RET_LABEL;
175 } else {
176 }
177 {
178 { /* Inline parser_nodes#AModule#n_imports (self) on <self:AModule> */
179 var10 = self->attrs[COLOR_parser_nodes__AModule___n_imports].val; /* _n_imports on <self:AModule> */
180 if (unlikely(var10 == NULL)) {
181 PRINT_ERROR("Runtime error: %s", "Uninitialized attribute _n_imports");
182 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_nodes.nit", 697);
183 show_backtrace(1);
184 }
185 var8 = var10;
186 RET_LABEL9:(void)0;
187 }
188 }
189 {
190 var11 = parser_nodes__ANodes__replace_child(var8, var_old_child, var_new_child);
191 }
192 if (var11){
193 goto RET_LABEL;
194 } else {
195 }
196 {
197 { /* Inline parser_nodes#AModule#n_extern_code_blocks (self) on <self:AModule> */
198 var14 = self->attrs[COLOR_parser_nodes__AModule___n_extern_code_blocks].val; /* _n_extern_code_blocks on <self:AModule> */
199 if (unlikely(var14 == NULL)) {
200 PRINT_ERROR("Runtime error: %s", "Uninitialized attribute _n_extern_code_blocks");
201 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_nodes.nit", 698);
202 show_backtrace(1);
203 }
204 var12 = var14;
205 RET_LABEL13:(void)0;
206 }
207 }
208 {
209 var15 = parser_nodes__ANodes__replace_child(var12, var_old_child, var_new_child);
210 }
211 if (var15){
212 goto RET_LABEL;
213 } else {
214 }
215 {
216 { /* Inline parser_nodes#AModule#n_classdefs (self) on <self:AModule> */
217 var18 = self->attrs[COLOR_parser_nodes__AModule___n_classdefs].val; /* _n_classdefs on <self:AModule> */
218 if (unlikely(var18 == NULL)) {
219 PRINT_ERROR("Runtime error: %s", "Uninitialized attribute _n_classdefs");
220 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_nodes.nit", 699);
221 show_backtrace(1);
222 }
223 var16 = var18;
224 RET_LABEL17:(void)0;
225 }
226 }
227 {
228 var19 = parser_nodes__ANodes__replace_child(var16, var_old_child, var_new_child);
229 }
230 if (var19){
231 goto RET_LABEL;
232 } else {
233 }
234 RET_LABEL:;
235 }
236 /* method parser_prod#AModule#replace_child for (self: Object, ANode, nullable ANode) */
237 void VIRTUAL_parser_prod__AModule__replace_child(val* self, val* p0, val* p1) {
238 parser_prod__AModule__replace_child(self, p0, p1); /* Direct call parser_prod#AModule#replace_child on <self:Object(AModule)>*/
239 RET_LABEL:;
240 }
241 /* method parser_prod#AModule#n_moduledecl= for (self: AModule, nullable AModuledecl) */
242 void parser_prod__AModule__n_moduledecl_61d(val* self, val* p0) {
243 val* var_node /* var node: nullable AModuledecl */;
244 val* var /* : null */;
245 short int var1 /* : Bool */;
246 short int var2 /* : Bool */;
247 val* var_other /* var other: nullable Object */;
248 short int var4 /* : Bool */;
249 short int var5 /* : Bool */;
250 short int var6 /* : Bool */;
251 var_node = p0;
252 self->attrs[COLOR_parser_nodes__AModule___n_moduledecl].val = var_node; /* _n_moduledecl on <self:AModule> */
253 var = NULL;
254 if (var_node == NULL) {
255 var1 = 0; /* is null */
256 } else {
257 var1 = 1; /* arg is null and recv is not */
258 }
259 if (0) {
260 { /* Inline kernel#Object#!= (var_node,var) on <var_node:nullable AModuledecl> */
261 var_other = var;
262 {
263 var5 = ((short int (*)(val*, val*))(var_node->class->vft[COLOR_kernel__Object___61d_61d]))(var_node, var_other) /* == on <var_node:nullable AModuledecl(AModuledecl)>*/;
264 var4 = var5;
265 }
266 var6 = !var4;
267 var2 = var6;
268 goto RET_LABEL3;
269 RET_LABEL3:(void)0;
270 }
271 var1 = var2;
272 }
273 if (var1){
274 {
275 { /* Inline parser_nodes#ANode#parent= (var_node,self) on <var_node:nullable AModuledecl(AModuledecl)> */
276 var_node->attrs[COLOR_parser_nodes__ANode___parent].val = self; /* _parent on <var_node:nullable AModuledecl(AModuledecl)> */
277 RET_LABEL7:(void)0;
278 }
279 }
280 } else {
281 }
282 RET_LABEL:;
283 }
284 /* method parser_prod#AModule#n_moduledecl= for (self: Object, nullable AModuledecl) */
285 void VIRTUAL_parser_prod__AModule__n_moduledecl_61d(val* self, val* p0) {
286 parser_prod__AModule__n_moduledecl_61d(self, p0); /* Direct call parser_prod#AModule#n_moduledecl= on <self:Object(AModule)>*/
287 RET_LABEL:;
288 }
289 /* method parser_prod#AModule#visit_all for (self: AModule, Visitor) */
290 void parser_prod__AModule__visit_all(val* self, val* p0) {
291 val* var_v /* var v: Visitor */;
292 val* var /* : nullable AModuledecl */;
293 val* var1 /* : ANodes[AImport] */;
294 val* var3 /* : ANodes[AImport] */;
295 val* var4 /* : ANodes[AExternCodeBlock] */;
296 val* var6 /* : ANodes[AExternCodeBlock] */;
297 val* var7 /* : ANodes[AClassdef] */;
298 val* var9 /* : ANodes[AClassdef] */;
299 var_v = p0;
300 var = self->attrs[COLOR_parser_nodes__AModule___n_moduledecl].val; /* _n_moduledecl on <self:AModule> */
301 {
302 parser_nodes__Visitor__enter_visit(var_v, var); /* Direct call parser_nodes#Visitor#enter_visit on <var_v:Visitor>*/
303 }
304 {
305 { /* Inline parser_nodes#AModule#n_imports (self) on <self:AModule> */
306 var3 = self->attrs[COLOR_parser_nodes__AModule___n_imports].val; /* _n_imports on <self:AModule> */
307 if (unlikely(var3 == NULL)) {
308 PRINT_ERROR("Runtime error: %s", "Uninitialized attribute _n_imports");
309 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_nodes.nit", 697);
310 show_backtrace(1);
311 }
312 var1 = var3;
313 RET_LABEL2:(void)0;
314 }
315 }
316 {
317 parser_nodes__ANodes__visit_all(var1, var_v); /* Direct call parser_nodes#ANodes#visit_all on <var1:ANodes[AImport]>*/
318 }
319 {
320 { /* Inline parser_nodes#AModule#n_extern_code_blocks (self) on <self:AModule> */
321 var6 = self->attrs[COLOR_parser_nodes__AModule___n_extern_code_blocks].val; /* _n_extern_code_blocks on <self:AModule> */
322 if (unlikely(var6 == NULL)) {
323 PRINT_ERROR("Runtime error: %s", "Uninitialized attribute _n_extern_code_blocks");
324 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_nodes.nit", 698);
325 show_backtrace(1);
326 }
327 var4 = var6;
328 RET_LABEL5:(void)0;
329 }
330 }
331 {
332 parser_nodes__ANodes__visit_all(var4, var_v); /* Direct call parser_nodes#ANodes#visit_all on <var4:ANodes[AExternCodeBlock]>*/
333 }
334 {
335 { /* Inline parser_nodes#AModule#n_classdefs (self) on <self:AModule> */
336 var9 = self->attrs[COLOR_parser_nodes__AModule___n_classdefs].val; /* _n_classdefs on <self:AModule> */
337 if (unlikely(var9 == NULL)) {
338 PRINT_ERROR("Runtime error: %s", "Uninitialized attribute _n_classdefs");
339 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_nodes.nit", 699);
340 show_backtrace(1);
341 }
342 var7 = var9;
343 RET_LABEL8:(void)0;
344 }
345 }
346 {
347 parser_nodes__ANodes__visit_all(var7, var_v); /* Direct call parser_nodes#ANodes#visit_all on <var7:ANodes[AClassdef]>*/
348 }
349 RET_LABEL:;
350 }
351 /* method parser_prod#AModule#visit_all for (self: Object, Visitor) */
352 void VIRTUAL_parser_prod__AModule__visit_all(val* self, val* p0) {
353 parser_prod__AModule__visit_all(self, p0); /* Direct call parser_prod#AModule#visit_all on <self:Object(AModule)>*/
354 RET_LABEL:;
355 }
356 /* method parser_prod#AModuledecl#init_amoduledecl for (self: AModuledecl, nullable ADoc, nullable TKwredef, nullable AVisibility, nullable TKwmodule, nullable AModuleName, nullable AAnnotations) */
357 void parser_prod__AModuledecl__init_amoduledecl(val* self, val* p0, val* p1, val* p2, val* p3, val* p4, val* p5) {
358 val* var_n_doc /* var n_doc: nullable ADoc */;
359 val* var_n_kwredef /* var n_kwredef: nullable TKwredef */;
360 val* var_n_visibility /* var n_visibility: nullable AVisibility */;
361 val* var_n_kwmodule /* var n_kwmodule: nullable TKwmodule */;
362 val* var_n_name /* var n_name: nullable AModuleName */;
363 val* var_n_annotations /* var n_annotations: nullable AAnnotations */;
364 val* var /* : null */;
365 short int var1 /* : Bool */;
366 short int var2 /* : Bool */;
367 val* var_other /* var other: nullable Object */;
368 short int var4 /* : Bool */;
369 short int var5 /* : Bool */;
370 short int var6 /* : Bool */;
371 val* var8 /* : null */;
372 short int var9 /* : Bool */;
373 short int var10 /* : Bool */;
374 short int var12 /* : Bool */;
375 short int var13 /* : Bool */;
376 short int var14 /* : Bool */;
377 val* var19 /* : null */;
378 short int var20 /* : Bool */;
379 short int var21 /* : Bool */;
380 short int var23 /* : Bool */;
381 short int var24 /* : Bool */;
382 short int var25 /* : Bool */;
383 var_n_doc = p0;
384 var_n_kwredef = p1;
385 var_n_visibility = p2;
386 var_n_kwmodule = p3;
387 var_n_name = p4;
388 var_n_annotations = p5;
389 self->attrs[COLOR_parser_nodes__AModuledecl___n_doc].val = var_n_doc; /* _n_doc on <self:AModuledecl> */
390 var = NULL;
391 if (var_n_doc == NULL) {
392 var1 = 0; /* is null */
393 } else {
394 var1 = 1; /* arg is null and recv is not */
395 }
396 if (0) {
397 { /* Inline kernel#Object#!= (var_n_doc,var) on <var_n_doc:nullable ADoc> */
398 var_other = var;
399 {
400 var5 = ((short int (*)(val*, val*))(var_n_doc->class->vft[COLOR_kernel__Object___61d_61d]))(var_n_doc, var_other) /* == on <var_n_doc:nullable ADoc(ADoc)>*/;
401 var4 = var5;
402 }
403 var6 = !var4;
404 var2 = var6;
405 goto RET_LABEL3;
406 RET_LABEL3:(void)0;
407 }
408 var1 = var2;
409 }
410 if (var1){
411 {
412 { /* Inline parser_nodes#ANode#parent= (var_n_doc,self) on <var_n_doc:nullable ADoc(ADoc)> */
413 var_n_doc->attrs[COLOR_parser_nodes__ANode___parent].val = self; /* _parent on <var_n_doc:nullable ADoc(ADoc)> */
414 RET_LABEL7:(void)0;
415 }
416 }
417 } else {
418 }
419 self->attrs[COLOR_parser_nodes__AModuledecl___n_kwredef].val = var_n_kwredef; /* _n_kwredef on <self:AModuledecl> */
420 var8 = NULL;
421 if (var_n_kwredef == NULL) {
422 var9 = 0; /* is null */
423 } else {
424 var9 = 1; /* arg is null and recv is not */
425 }
426 if (0) {
427 { /* Inline kernel#Object#!= (var_n_kwredef,var8) on <var_n_kwredef:nullable TKwredef> */
428 var_other = var8;
429 {
430 var13 = ((short int (*)(val*, val*))(var_n_kwredef->class->vft[COLOR_kernel__Object___61d_61d]))(var_n_kwredef, var_other) /* == on <var_n_kwredef:nullable TKwredef(TKwredef)>*/;
431 var12 = var13;
432 }
433 var14 = !var12;
434 var10 = var14;
435 goto RET_LABEL11;
436 RET_LABEL11:(void)0;
437 }
438 var9 = var10;
439 }
440 if (var9){
441 {
442 { /* Inline parser_nodes#ANode#parent= (var_n_kwredef,self) on <var_n_kwredef:nullable TKwredef(TKwredef)> */
443 var_n_kwredef->attrs[COLOR_parser_nodes__ANode___parent].val = self; /* _parent on <var_n_kwredef:nullable TKwredef(TKwredef)> */
444 RET_LABEL15:(void)0;
445 }
446 }
447 } else {
448 }
449 if (unlikely(var_n_visibility == NULL)) {
450 PRINT_ERROR("Runtime error: %s", "Cast failed");
451 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 64);
452 show_backtrace(1);
453 }
454 self->attrs[COLOR_parser_nodes__AModuledecl___n_visibility].val = var_n_visibility; /* _n_visibility on <self:AModuledecl> */
455 if (var_n_visibility == NULL) {
456 PRINT_ERROR("Runtime error: %s", "Receiver is null");
457 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 65);
458 show_backtrace(1);
459 } else {
460 { /* Inline parser_nodes#ANode#parent= (var_n_visibility,self) on <var_n_visibility:nullable AVisibility> */
461 if (unlikely(var_n_visibility == NULL)) {
462 PRINT_ERROR("Runtime error: %s", "Receiver is null");
463 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_nodes.nit", 38);
464 show_backtrace(1);
465 }
466 var_n_visibility->attrs[COLOR_parser_nodes__ANode___parent].val = self; /* _parent on <var_n_visibility:nullable AVisibility> */
467 RET_LABEL16:(void)0;
468 }
469 }
470 if (unlikely(var_n_kwmodule == NULL)) {
471 PRINT_ERROR("Runtime error: %s", "Cast failed");
472 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 66);
473 show_backtrace(1);
474 }
475 self->attrs[COLOR_parser_nodes__AModuledecl___n_kwmodule].val = var_n_kwmodule; /* _n_kwmodule on <self:AModuledecl> */
476 if (var_n_kwmodule == NULL) {
477 PRINT_ERROR("Runtime error: %s", "Receiver is null");
478 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 67);
479 show_backtrace(1);
480 } else {
481 { /* Inline parser_nodes#ANode#parent= (var_n_kwmodule,self) on <var_n_kwmodule:nullable TKwmodule> */
482 if (unlikely(var_n_kwmodule == NULL)) {
483 PRINT_ERROR("Runtime error: %s", "Receiver is null");
484 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_nodes.nit", 38);
485 show_backtrace(1);
486 }
487 var_n_kwmodule->attrs[COLOR_parser_nodes__ANode___parent].val = self; /* _parent on <var_n_kwmodule:nullable TKwmodule> */
488 RET_LABEL17:(void)0;
489 }
490 }
491 if (unlikely(var_n_name == NULL)) {
492 PRINT_ERROR("Runtime error: %s", "Cast failed");
493 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 68);
494 show_backtrace(1);
495 }
496 self->attrs[COLOR_parser_nodes__AModuledecl___n_name].val = var_n_name; /* _n_name on <self:AModuledecl> */
497 if (var_n_name == NULL) {
498 PRINT_ERROR("Runtime error: %s", "Receiver is null");
499 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 69);
500 show_backtrace(1);
501 } else {
502 { /* Inline parser_nodes#ANode#parent= (var_n_name,self) on <var_n_name:nullable AModuleName> */
503 if (unlikely(var_n_name == NULL)) {
504 PRINT_ERROR("Runtime error: %s", "Receiver is null");
505 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_nodes.nit", 38);
506 show_backtrace(1);
507 }
508 var_n_name->attrs[COLOR_parser_nodes__ANode___parent].val = self; /* _parent on <var_n_name:nullable AModuleName> */
509 RET_LABEL18:(void)0;
510 }
511 }
512 self->attrs[COLOR_parser_nodes__Prod___n_annotations].val = var_n_annotations; /* _n_annotations on <self:AModuledecl> */
513 var19 = NULL;
514 if (var_n_annotations == NULL) {
515 var20 = 0; /* is null */
516 } else {
517 var20 = 1; /* arg is null and recv is not */
518 }
519 if (0) {
520 { /* Inline kernel#Object#!= (var_n_annotations,var19) on <var_n_annotations:nullable AAnnotations> */
521 var_other = var19;
522 {
523 var24 = ((short int (*)(val*, val*))(var_n_annotations->class->vft[COLOR_kernel__Object___61d_61d]))(var_n_annotations, var_other) /* == on <var_n_annotations:nullable AAnnotations(AAnnotations)>*/;
524 var23 = var24;
525 }
526 var25 = !var23;
527 var21 = var25;
528 goto RET_LABEL22;
529 RET_LABEL22:(void)0;
530 }
531 var20 = var21;
532 }
533 if (var20){
534 {
535 { /* Inline parser_nodes#ANode#parent= (var_n_annotations,self) on <var_n_annotations:nullable AAnnotations(AAnnotations)> */
536 var_n_annotations->attrs[COLOR_parser_nodes__ANode___parent].val = self; /* _parent on <var_n_annotations:nullable AAnnotations(AAnnotations)> */
537 RET_LABEL26:(void)0;
538 }
539 }
540 } else {
541 }
542 RET_LABEL:;
543 }
544 /* method parser_prod#AModuledecl#init_amoduledecl for (self: Object, nullable ADoc, nullable TKwredef, nullable AVisibility, nullable TKwmodule, nullable AModuleName, nullable AAnnotations) */
545 void VIRTUAL_parser_prod__AModuledecl__init_amoduledecl(val* self, val* p0, val* p1, val* p2, val* p3, val* p4, val* p5) {
546 parser_prod__AModuledecl__init_amoduledecl(self, p0, p1, p2, p3, p4, p5); /* Direct call parser_prod#AModuledecl#init_amoduledecl on <self:Object(AModuledecl)>*/
547 RET_LABEL:;
548 }
549 /* method parser_prod#AModuledecl#replace_child for (self: AModuledecl, ANode, nullable ANode) */
550 void parser_prod__AModuledecl__replace_child(val* self, val* p0, val* p1) {
551 val* var_old_child /* var old_child: ANode */;
552 val* var_new_child /* var new_child: nullable ANode */;
553 val* var /* : nullable ADoc */;
554 short int var1 /* : Bool */;
555 short int var2 /* : Bool */;
556 val* var_other /* var other: nullable Object */;
557 short int var4 /* : Bool */;
558 short int var6 /* : Bool */;
559 short int var7 /* : Bool */;
560 int cltype;
561 int idtype;
562 const char* var_class_name;
563 val* var8 /* : nullable TKwredef */;
564 short int var9 /* : Bool */;
565 short int var10 /* : Bool */;
566 short int var12 /* : Bool */;
567 short int var14 /* : Bool */;
568 short int var15 /* : Bool */;
569 int cltype16;
570 int idtype17;
571 const char* var_class_name18;
572 val* var19 /* : AVisibility */;
573 short int var20 /* : Bool */;
574 short int var21 /* : Bool */;
575 short int var23 /* : Bool */;
576 short int var25 /* : Bool */;
577 short int var26 /* : Bool */;
578 int cltype27;
579 int idtype28;
580 const char* var_class_name29;
581 val* var30 /* : TKwmodule */;
582 short int var31 /* : Bool */;
583 short int var32 /* : Bool */;
584 short int var34 /* : Bool */;
585 short int var36 /* : Bool */;
586 short int var37 /* : Bool */;
587 int cltype38;
588 int idtype39;
589 const char* var_class_name40;
590 val* var41 /* : AModuleName */;
591 short int var42 /* : Bool */;
592 short int var43 /* : Bool */;
593 short int var45 /* : Bool */;
594 short int var47 /* : Bool */;
595 short int var48 /* : Bool */;
596 int cltype49;
597 int idtype50;
598 const char* var_class_name51;
599 val* var52 /* : nullable AAnnotations */;
600 short int var53 /* : Bool */;
601 short int var54 /* : Bool */;
602 short int var56 /* : Bool */;
603 short int var58 /* : Bool */;
604 short int var59 /* : Bool */;
605 int cltype60;
606 int idtype61;
607 const char* var_class_name62;
608 var_old_child = p0;
609 var_new_child = p1;
610 var = self->attrs[COLOR_parser_nodes__AModuledecl___n_doc].val; /* _n_doc on <self:AModuledecl> */
611 if (var == NULL) {
612 var1 = 0; /* <var_old_child:ANode> cannot be null */
613 } else {
614 { /* Inline kernel#Object#== (var,var_old_child) on <var:nullable ADoc> */
615 var_other = var_old_child;
616 {
617 { /* Inline kernel#Object#is_same_instance (var,var_other) on <var:nullable ADoc(ADoc)> */
618 var6 = var == var_other;
619 var4 = var6;
620 goto RET_LABEL5;
621 RET_LABEL5:(void)0;
622 }
623 }
624 var2 = var4;
625 goto RET_LABEL3;
626 RET_LABEL3:(void)0;
627 }
628 var1 = var2;
629 }
630 if (var1){
631 /* <var_new_child:nullable ANode> isa nullable ADoc */
632 cltype = type_nullable_parser_nodes__ADoc.color;
633 idtype = type_nullable_parser_nodes__ADoc.id;
634 if(var_new_child == NULL) {
635 var7 = 1;
636 } else {
637 if(cltype >= var_new_child->type->table_size) {
638 var7 = 0;
639 } else {
640 var7 = var_new_child->type->type_table[cltype] == idtype;
641 }
642 }
643 if (unlikely(!var7)) {
644 var_class_name = var_new_child == NULL ? "null" : var_new_child->type->name;
645 PRINT_ERROR("Runtime error: Cast failed. Expected `%s`, got `%s`", "nullable ADoc", var_class_name);
646 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 77);
647 show_backtrace(1);
648 }
649 {
650 parser_prod__AModuledecl__n_doc_61d(self, var_new_child); /* Direct call parser_prod#AModuledecl#n_doc= on <self:AModuledecl>*/
651 }
652 goto RET_LABEL;
653 } else {
654 }
655 var8 = self->attrs[COLOR_parser_nodes__AModuledecl___n_kwredef].val; /* _n_kwredef on <self:AModuledecl> */
656 if (var8 == NULL) {
657 var9 = 0; /* <var_old_child:ANode> cannot be null */
658 } else {
659 { /* Inline kernel#Object#== (var8,var_old_child) on <var8:nullable TKwredef> */
660 var_other = var_old_child;
661 {
662 { /* Inline kernel#Object#is_same_instance (var8,var_other) on <var8:nullable TKwredef(TKwredef)> */
663 var14 = var8 == var_other;
664 var12 = var14;
665 goto RET_LABEL13;
666 RET_LABEL13:(void)0;
667 }
668 }
669 var10 = var12;
670 goto RET_LABEL11;
671 RET_LABEL11:(void)0;
672 }
673 var9 = var10;
674 }
675 if (var9){
676 /* <var_new_child:nullable ANode> isa nullable TKwredef */
677 cltype16 = type_nullable_parser_nodes__TKwredef.color;
678 idtype17 = type_nullable_parser_nodes__TKwredef.id;
679 if(var_new_child == NULL) {
680 var15 = 1;
681 } else {
682 if(cltype16 >= var_new_child->type->table_size) {
683 var15 = 0;
684 } else {
685 var15 = var_new_child->type->type_table[cltype16] == idtype17;
686 }
687 }
688 if (unlikely(!var15)) {
689 var_class_name18 = var_new_child == NULL ? "null" : var_new_child->type->name;
690 PRINT_ERROR("Runtime error: Cast failed. Expected `%s`, got `%s`", "nullable TKwredef", var_class_name18);
691 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 81);
692 show_backtrace(1);
693 }
694 {
695 parser_prod__AModuledecl__n_kwredef_61d(self, var_new_child); /* Direct call parser_prod#AModuledecl#n_kwredef= on <self:AModuledecl>*/
696 }
697 goto RET_LABEL;
698 } else {
699 }
700 var19 = self->attrs[COLOR_parser_nodes__AModuledecl___n_visibility].val; /* _n_visibility on <self:AModuledecl> */
701 if (unlikely(var19 == NULL)) {
702 PRINT_ERROR("Runtime error: %s", "Uninitialized attribute _n_visibility");
703 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 84);
704 show_backtrace(1);
705 }
706 {
707 { /* Inline kernel#Object#== (var19,var_old_child) on <var19:AVisibility> */
708 var_other = var_old_child;
709 {
710 { /* Inline kernel#Object#is_same_instance (var19,var_other) on <var19:AVisibility> */
711 var25 = var19 == var_other;
712 var23 = var25;
713 goto RET_LABEL24;
714 RET_LABEL24:(void)0;
715 }
716 }
717 var21 = var23;
718 goto RET_LABEL22;
719 RET_LABEL22:(void)0;
720 }
721 var20 = var21;
722 }
723 if (var20){
724 /* <var_new_child:nullable ANode> isa AVisibility */
725 cltype27 = type_parser_nodes__AVisibility.color;
726 idtype28 = type_parser_nodes__AVisibility.id;
727 if(var_new_child == NULL) {
728 var26 = 0;
729 } else {
730 if(cltype27 >= var_new_child->type->table_size) {
731 var26 = 0;
732 } else {
733 var26 = var_new_child->type->type_table[cltype27] == idtype28;
734 }
735 }
736 if (unlikely(!var26)) {
737 var_class_name29 = var_new_child == NULL ? "null" : var_new_child->type->name;
738 PRINT_ERROR("Runtime error: Cast failed. Expected `%s`, got `%s`", "AVisibility", var_class_name29);
739 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 85);
740 show_backtrace(1);
741 }
742 {
743 parser_prod__AModuledecl__n_visibility_61d(self, var_new_child); /* Direct call parser_prod#AModuledecl#n_visibility= on <self:AModuledecl>*/
744 }
745 goto RET_LABEL;
746 } else {
747 }
748 var30 = self->attrs[COLOR_parser_nodes__AModuledecl___n_kwmodule].val; /* _n_kwmodule on <self:AModuledecl> */
749 if (unlikely(var30 == NULL)) {
750 PRINT_ERROR("Runtime error: %s", "Uninitialized attribute _n_kwmodule");
751 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 88);
752 show_backtrace(1);
753 }
754 {
755 { /* Inline kernel#Object#== (var30,var_old_child) on <var30:TKwmodule> */
756 var_other = var_old_child;
757 {
758 { /* Inline kernel#Object#is_same_instance (var30,var_other) on <var30:TKwmodule> */
759 var36 = var30 == var_other;
760 var34 = var36;
761 goto RET_LABEL35;
762 RET_LABEL35:(void)0;
763 }
764 }
765 var32 = var34;
766 goto RET_LABEL33;
767 RET_LABEL33:(void)0;
768 }
769 var31 = var32;
770 }
771 if (var31){
772 /* <var_new_child:nullable ANode> isa TKwmodule */
773 cltype38 = type_parser_nodes__TKwmodule.color;
774 idtype39 = type_parser_nodes__TKwmodule.id;
775 if(var_new_child == NULL) {
776 var37 = 0;
777 } else {
778 if(cltype38 >= var_new_child->type->table_size) {
779 var37 = 0;
780 } else {
781 var37 = var_new_child->type->type_table[cltype38] == idtype39;
782 }
783 }
784 if (unlikely(!var37)) {
785 var_class_name40 = var_new_child == NULL ? "null" : var_new_child->type->name;
786 PRINT_ERROR("Runtime error: Cast failed. Expected `%s`, got `%s`", "TKwmodule", var_class_name40);
787 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 89);
788 show_backtrace(1);
789 }
790 {
791 parser_prod__AModuledecl__n_kwmodule_61d(self, var_new_child); /* Direct call parser_prod#AModuledecl#n_kwmodule= on <self:AModuledecl>*/
792 }
793 goto RET_LABEL;
794 } else {
795 }
796 var41 = self->attrs[COLOR_parser_nodes__AModuledecl___n_name].val; /* _n_name on <self:AModuledecl> */
797 if (unlikely(var41 == NULL)) {
798 PRINT_ERROR("Runtime error: %s", "Uninitialized attribute _n_name");
799 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 92);
800 show_backtrace(1);
801 }
802 {
803 { /* Inline kernel#Object#== (var41,var_old_child) on <var41:AModuleName> */
804 var_other = var_old_child;
805 {
806 { /* Inline kernel#Object#is_same_instance (var41,var_other) on <var41:AModuleName> */
807 var47 = var41 == var_other;
808 var45 = var47;
809 goto RET_LABEL46;
810 RET_LABEL46:(void)0;
811 }
812 }
813 var43 = var45;
814 goto RET_LABEL44;
815 RET_LABEL44:(void)0;
816 }
817 var42 = var43;
818 }
819 if (var42){
820 /* <var_new_child:nullable ANode> isa AModuleName */
821 cltype49 = type_parser_nodes__AModuleName.color;
822 idtype50 = type_parser_nodes__AModuleName.id;
823 if(var_new_child == NULL) {
824 var48 = 0;
825 } else {
826 if(cltype49 >= var_new_child->type->table_size) {
827 var48 = 0;
828 } else {
829 var48 = var_new_child->type->type_table[cltype49] == idtype50;
830 }
831 }
832 if (unlikely(!var48)) {
833 var_class_name51 = var_new_child == NULL ? "null" : var_new_child->type->name;
834 PRINT_ERROR("Runtime error: Cast failed. Expected `%s`, got `%s`", "AModuleName", var_class_name51);
835 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 93);
836 show_backtrace(1);
837 }
838 {
839 parser_prod__AModuledecl__n_name_61d(self, var_new_child); /* Direct call parser_prod#AModuledecl#n_name= on <self:AModuledecl>*/
840 }
841 goto RET_LABEL;
842 } else {
843 }
844 var52 = self->attrs[COLOR_parser_nodes__Prod___n_annotations].val; /* _n_annotations on <self:AModuledecl> */
845 if (var52 == NULL) {
846 var53 = 0; /* <var_old_child:ANode> cannot be null */
847 } else {
848 { /* Inline kernel#Object#== (var52,var_old_child) on <var52:nullable AAnnotations> */
849 var_other = var_old_child;
850 {
851 { /* Inline kernel#Object#is_same_instance (var52,var_other) on <var52:nullable AAnnotations(AAnnotations)> */
852 var58 = var52 == var_other;
853 var56 = var58;
854 goto RET_LABEL57;
855 RET_LABEL57:(void)0;
856 }
857 }
858 var54 = var56;
859 goto RET_LABEL55;
860 RET_LABEL55:(void)0;
861 }
862 var53 = var54;
863 }
864 if (var53){
865 /* <var_new_child:nullable ANode> isa nullable AAnnotations */
866 cltype60 = type_nullable_parser_nodes__AAnnotations.color;
867 idtype61 = type_nullable_parser_nodes__AAnnotations.id;
868 if(var_new_child == NULL) {
869 var59 = 1;
870 } else {
871 if(cltype60 >= var_new_child->type->table_size) {
872 var59 = 0;
873 } else {
874 var59 = var_new_child->type->type_table[cltype60] == idtype61;
875 }
876 }
877 if (unlikely(!var59)) {
878 var_class_name62 = var_new_child == NULL ? "null" : var_new_child->type->name;
879 PRINT_ERROR("Runtime error: Cast failed. Expected `%s`, got `%s`", "nullable AAnnotations", var_class_name62);
880 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 97);
881 show_backtrace(1);
882 }
883 {
884 parser_prod__AModuledecl__n_annotations_61d(self, var_new_child); /* Direct call parser_prod#AModuledecl#n_annotations= on <self:AModuledecl>*/
885 }
886 goto RET_LABEL;
887 } else {
888 }
889 RET_LABEL:;
890 }
891 /* method parser_prod#AModuledecl#replace_child for (self: Object, ANode, nullable ANode) */
892 void VIRTUAL_parser_prod__AModuledecl__replace_child(val* self, val* p0, val* p1) {
893 parser_prod__AModuledecl__replace_child(self, p0, p1); /* Direct call parser_prod#AModuledecl#replace_child on <self:Object(AModuledecl)>*/
894 RET_LABEL:;
895 }
896 /* method parser_prod#AModuledecl#n_doc= for (self: AModuledecl, nullable ADoc) */
897 void parser_prod__AModuledecl__n_doc_61d(val* self, val* p0) {
898 val* var_node /* var node: nullable ADoc */;
899 val* var /* : null */;
900 short int var1 /* : Bool */;
901 short int var2 /* : Bool */;
902 val* var_other /* var other: nullable Object */;
903 short int var4 /* : Bool */;
904 short int var5 /* : Bool */;
905 short int var6 /* : Bool */;
906 var_node = p0;
907 self->attrs[COLOR_parser_nodes__AModuledecl___n_doc].val = var_node; /* _n_doc on <self:AModuledecl> */
908 var = NULL;
909 if (var_node == NULL) {
910 var1 = 0; /* is null */
911 } else {
912 var1 = 1; /* arg is null and recv is not */
913 }
914 if (0) {
915 { /* Inline kernel#Object#!= (var_node,var) on <var_node:nullable ADoc> */
916 var_other = var;
917 {
918 var5 = ((short int (*)(val*, val*))(var_node->class->vft[COLOR_kernel__Object___61d_61d]))(var_node, var_other) /* == on <var_node:nullable ADoc(ADoc)>*/;
919 var4 = var5;
920 }
921 var6 = !var4;
922 var2 = var6;
923 goto RET_LABEL3;
924 RET_LABEL3:(void)0;
925 }
926 var1 = var2;
927 }
928 if (var1){
929 {
930 { /* Inline parser_nodes#ANode#parent= (var_node,self) on <var_node:nullable ADoc(ADoc)> */
931 var_node->attrs[COLOR_parser_nodes__ANode___parent].val = self; /* _parent on <var_node:nullable ADoc(ADoc)> */
932 RET_LABEL7:(void)0;
933 }
934 }
935 } else {
936 }
937 RET_LABEL:;
938 }
939 /* method parser_prod#AModuledecl#n_doc= for (self: Object, nullable ADoc) */
940 void VIRTUAL_parser_prod__AModuledecl__n_doc_61d(val* self, val* p0) {
941 parser_prod__AModuledecl__n_doc_61d(self, p0); /* Direct call parser_prod#AModuledecl#n_doc= on <self:Object(AModuledecl)>*/
942 RET_LABEL:;
943 }
944 /* method parser_prod#AModuledecl#n_kwredef= for (self: AModuledecl, nullable TKwredef) */
945 void parser_prod__AModuledecl__n_kwredef_61d(val* self, val* p0) {
946 val* var_node /* var node: nullable TKwredef */;
947 val* var /* : null */;
948 short int var1 /* : Bool */;
949 short int var2 /* : Bool */;
950 val* var_other /* var other: nullable Object */;
951 short int var4 /* : Bool */;
952 short int var5 /* : Bool */;
953 short int var6 /* : Bool */;
954 var_node = p0;
955 self->attrs[COLOR_parser_nodes__AModuledecl___n_kwredef].val = var_node; /* _n_kwredef on <self:AModuledecl> */
956 var = NULL;
957 if (var_node == NULL) {
958 var1 = 0; /* is null */
959 } else {
960 var1 = 1; /* arg is null and recv is not */
961 }
962 if (0) {
963 { /* Inline kernel#Object#!= (var_node,var) on <var_node:nullable TKwredef> */
964 var_other = var;
965 {
966 var5 = ((short int (*)(val*, val*))(var_node->class->vft[COLOR_kernel__Object___61d_61d]))(var_node, var_other) /* == on <var_node:nullable TKwredef(TKwredef)>*/;
967 var4 = var5;
968 }
969 var6 = !var4;
970 var2 = var6;
971 goto RET_LABEL3;
972 RET_LABEL3:(void)0;
973 }
974 var1 = var2;
975 }
976 if (var1){
977 {
978 { /* Inline parser_nodes#ANode#parent= (var_node,self) on <var_node:nullable TKwredef(TKwredef)> */
979 var_node->attrs[COLOR_parser_nodes__ANode___parent].val = self; /* _parent on <var_node:nullable TKwredef(TKwredef)> */
980 RET_LABEL7:(void)0;
981 }
982 }
983 } else {
984 }
985 RET_LABEL:;
986 }
987 /* method parser_prod#AModuledecl#n_kwredef= for (self: Object, nullable TKwredef) */
988 void VIRTUAL_parser_prod__AModuledecl__n_kwredef_61d(val* self, val* p0) {
989 parser_prod__AModuledecl__n_kwredef_61d(self, p0); /* Direct call parser_prod#AModuledecl#n_kwredef= on <self:Object(AModuledecl)>*/
990 RET_LABEL:;
991 }
992 /* method parser_prod#AModuledecl#n_visibility= for (self: AModuledecl, AVisibility) */
993 void parser_prod__AModuledecl__n_visibility_61d(val* self, val* p0) {
994 val* var_node /* var node: AVisibility */;
995 var_node = p0;
996 self->attrs[COLOR_parser_nodes__AModuledecl___n_visibility].val = var_node; /* _n_visibility on <self:AModuledecl> */
997 {
998 { /* Inline parser_nodes#ANode#parent= (var_node,self) on <var_node:AVisibility> */
999 var_node->attrs[COLOR_parser_nodes__ANode___parent].val = self; /* _parent on <var_node:AVisibility> */
1000 RET_LABEL1:(void)0;
1001 }
1002 }
1003 RET_LABEL:;
1004 }
1005 /* method parser_prod#AModuledecl#n_visibility= for (self: Object, AVisibility) */
1006 void VIRTUAL_parser_prod__AModuledecl__n_visibility_61d(val* self, val* p0) {
1007 parser_prod__AModuledecl__n_visibility_61d(self, p0); /* Direct call parser_prod#AModuledecl#n_visibility= on <self:Object(AModuledecl)>*/
1008 RET_LABEL:;
1009 }
1010 /* method parser_prod#AModuledecl#n_kwmodule= for (self: AModuledecl, TKwmodule) */
1011 void parser_prod__AModuledecl__n_kwmodule_61d(val* self, val* p0) {
1012 val* var_node /* var node: TKwmodule */;
1013 var_node = p0;
1014 self->attrs[COLOR_parser_nodes__AModuledecl___n_kwmodule].val = var_node; /* _n_kwmodule on <self:AModuledecl> */
1015 {
1016 { /* Inline parser_nodes#ANode#parent= (var_node,self) on <var_node:TKwmodule> */
1017 var_node->attrs[COLOR_parser_nodes__ANode___parent].val = self; /* _parent on <var_node:TKwmodule> */
1018 RET_LABEL1:(void)0;
1019 }
1020 }
1021 RET_LABEL:;
1022 }
1023 /* method parser_prod#AModuledecl#n_kwmodule= for (self: Object, TKwmodule) */
1024 void VIRTUAL_parser_prod__AModuledecl__n_kwmodule_61d(val* self, val* p0) {
1025 parser_prod__AModuledecl__n_kwmodule_61d(self, p0); /* Direct call parser_prod#AModuledecl#n_kwmodule= on <self:Object(AModuledecl)>*/
1026 RET_LABEL:;
1027 }
1028 /* method parser_prod#AModuledecl#n_name= for (self: AModuledecl, AModuleName) */
1029 void parser_prod__AModuledecl__n_name_61d(val* self, val* p0) {
1030 val* var_node /* var node: AModuleName */;
1031 var_node = p0;
1032 self->attrs[COLOR_parser_nodes__AModuledecl___n_name].val = var_node; /* _n_name on <self:AModuledecl> */
1033 {
1034 { /* Inline parser_nodes#ANode#parent= (var_node,self) on <var_node:AModuleName> */
1035 var_node->attrs[COLOR_parser_nodes__ANode___parent].val = self; /* _parent on <var_node:AModuleName> */
1036 RET_LABEL1:(void)0;
1037 }
1038 }
1039 RET_LABEL:;
1040 }
1041 /* method parser_prod#AModuledecl#n_name= for (self: Object, AModuleName) */
1042 void VIRTUAL_parser_prod__AModuledecl__n_name_61d(val* self, val* p0) {
1043 parser_prod__AModuledecl__n_name_61d(self, p0); /* Direct call parser_prod#AModuledecl#n_name= on <self:Object(AModuledecl)>*/
1044 RET_LABEL:;
1045 }
1046 /* method parser_prod#AModuledecl#n_annotations= for (self: AModuledecl, nullable AAnnotations) */
1047 void parser_prod__AModuledecl__n_annotations_61d(val* self, val* p0) {
1048 val* var_node /* var node: nullable AAnnotations */;
1049 val* var /* : null */;
1050 short int var1 /* : Bool */;
1051 short int var2 /* : Bool */;
1052 val* var_other /* var other: nullable Object */;
1053 short int var4 /* : Bool */;
1054 short int var5 /* : Bool */;
1055 short int var6 /* : Bool */;
1056 var_node = p0;
1057 self->attrs[COLOR_parser_nodes__Prod___n_annotations].val = var_node; /* _n_annotations on <self:AModuledecl> */
1058 var = NULL;
1059 if (var_node == NULL) {
1060 var1 = 0; /* is null */
1061 } else {
1062 var1 = 1; /* arg is null and recv is not */
1063 }
1064 if (0) {
1065 { /* Inline kernel#Object#!= (var_node,var) on <var_node:nullable AAnnotations> */
1066 var_other = var;
1067 {
1068 var5 = ((short int (*)(val*, val*))(var_node->class->vft[COLOR_kernel__Object___61d_61d]))(var_node, var_other) /* == on <var_node:nullable AAnnotations(AAnnotations)>*/;
1069 var4 = var5;
1070 }
1071 var6 = !var4;
1072 var2 = var6;
1073 goto RET_LABEL3;
1074 RET_LABEL3:(void)0;
1075 }
1076 var1 = var2;
1077 }
1078 if (var1){
1079 {
1080 { /* Inline parser_nodes#ANode#parent= (var_node,self) on <var_node:nullable AAnnotations(AAnnotations)> */
1081 var_node->attrs[COLOR_parser_nodes__ANode___parent].val = self; /* _parent on <var_node:nullable AAnnotations(AAnnotations)> */
1082 RET_LABEL7:(void)0;
1083 }
1084 }
1085 } else {
1086 }
1087 RET_LABEL:;
1088 }
1089 /* method parser_prod#AModuledecl#n_annotations= for (self: Object, nullable AAnnotations) */
1090 void VIRTUAL_parser_prod__AModuledecl__n_annotations_61d(val* self, val* p0) {
1091 parser_prod__AModuledecl__n_annotations_61d(self, p0); /* Direct call parser_prod#AModuledecl#n_annotations= on <self:Object(AModuledecl)>*/
1092 RET_LABEL:;
1093 }
1094 /* method parser_prod#AModuledecl#visit_all for (self: AModuledecl, Visitor) */
1095 void parser_prod__AModuledecl__visit_all(val* self, val* p0) {
1096 val* var_v /* var v: Visitor */;
1097 val* var /* : nullable ADoc */;
1098 val* var1 /* : nullable TKwredef */;
1099 val* var2 /* : AVisibility */;
1100 val* var3 /* : TKwmodule */;
1101 val* var4 /* : AModuleName */;
1102 val* var5 /* : nullable AAnnotations */;
1103 var_v = p0;
1104 var = self->attrs[COLOR_parser_nodes__AModuledecl___n_doc].val; /* _n_doc on <self:AModuledecl> */
1105 {
1106 parser_nodes__Visitor__enter_visit(var_v, var); /* Direct call parser_nodes#Visitor#enter_visit on <var_v:Visitor>*/
1107 }
1108 var1 = self->attrs[COLOR_parser_nodes__AModuledecl___n_kwredef].val; /* _n_kwredef on <self:AModuledecl> */
1109 {
1110 parser_nodes__Visitor__enter_visit(var_v, var1); /* Direct call parser_nodes#Visitor#enter_visit on <var_v:Visitor>*/
1111 }
1112 var2 = self->attrs[COLOR_parser_nodes__AModuledecl___n_visibility].val; /* _n_visibility on <self:AModuledecl> */
1113 if (unlikely(var2 == NULL)) {
1114 PRINT_ERROR("Runtime error: %s", "Uninitialized attribute _n_visibility");
1115 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 138);
1116 show_backtrace(1);
1117 }
1118 {
1119 parser_nodes__Visitor__enter_visit(var_v, var2); /* Direct call parser_nodes#Visitor#enter_visit on <var_v:Visitor>*/
1120 }
1121 var3 = self->attrs[COLOR_parser_nodes__AModuledecl___n_kwmodule].val; /* _n_kwmodule on <self:AModuledecl> */
1122 if (unlikely(var3 == NULL)) {
1123 PRINT_ERROR("Runtime error: %s", "Uninitialized attribute _n_kwmodule");
1124 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 139);
1125 show_backtrace(1);
1126 }
1127 {
1128 parser_nodes__Visitor__enter_visit(var_v, var3); /* Direct call parser_nodes#Visitor#enter_visit on <var_v:Visitor>*/
1129 }
1130 var4 = self->attrs[COLOR_parser_nodes__AModuledecl___n_name].val; /* _n_name on <self:AModuledecl> */
1131 if (unlikely(var4 == NULL)) {
1132 PRINT_ERROR("Runtime error: %s", "Uninitialized attribute _n_name");
1133 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 140);
1134 show_backtrace(1);
1135 }
1136 {
1137 parser_nodes__Visitor__enter_visit(var_v, var4); /* Direct call parser_nodes#Visitor#enter_visit on <var_v:Visitor>*/
1138 }
1139 var5 = self->attrs[COLOR_parser_nodes__Prod___n_annotations].val; /* _n_annotations on <self:AModuledecl> */
1140 {
1141 parser_nodes__Visitor__enter_visit(var_v, var5); /* Direct call parser_nodes#Visitor#enter_visit on <var_v:Visitor>*/
1142 }
1143 RET_LABEL:;
1144 }
1145 /* method parser_prod#AModuledecl#visit_all for (self: Object, Visitor) */
1146 void VIRTUAL_parser_prod__AModuledecl__visit_all(val* self, val* p0) {
1147 parser_prod__AModuledecl__visit_all(self, p0); /* Direct call parser_prod#AModuledecl#visit_all on <self:Object(AModuledecl)>*/
1148 RET_LABEL:;
1149 }
1150 /* method parser_prod#AStdImport#init_astdimport for (self: AStdImport, nullable AVisibility, nullable TKwimport, nullable AModuleName, nullable AAnnotations) */
1151 void parser_prod__AStdImport__init_astdimport(val* self, val* p0, val* p1, val* p2, val* p3) {
1152 val* var_n_visibility /* var n_visibility: nullable AVisibility */;
1153 val* var_n_kwimport /* var n_kwimport: nullable TKwimport */;
1154 val* var_n_name /* var n_name: nullable AModuleName */;
1155 val* var_n_annotations /* var n_annotations: nullable AAnnotations */;
1156 val* var /* : null */;
1157 short int var4 /* : Bool */;
1158 short int var5 /* : Bool */;
1159 val* var_other /* var other: nullable Object */;
1160 short int var7 /* : Bool */;
1161 short int var8 /* : Bool */;
1162 short int var9 /* : Bool */;
1163 var_n_visibility = p0;
1164 var_n_kwimport = p1;
1165 var_n_name = p2;
1166 var_n_annotations = p3;
1167 if (unlikely(var_n_visibility == NULL)) {
1168 PRINT_ERROR("Runtime error: %s", "Cast failed");
1169 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 152);
1170 show_backtrace(1);
1171 }
1172 self->attrs[COLOR_parser_nodes__AStdImport___n_visibility].val = var_n_visibility; /* _n_visibility on <self:AStdImport> */
1173 if (var_n_visibility == NULL) {
1174 PRINT_ERROR("Runtime error: %s", "Receiver is null");
1175 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 153);
1176 show_backtrace(1);
1177 } else {
1178 { /* Inline parser_nodes#ANode#parent= (var_n_visibility,self) on <var_n_visibility:nullable AVisibility> */
1179 if (unlikely(var_n_visibility == NULL)) {
1180 PRINT_ERROR("Runtime error: %s", "Receiver is null");
1181 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_nodes.nit", 38);
1182 show_backtrace(1);
1183 }
1184 var_n_visibility->attrs[COLOR_parser_nodes__ANode___parent].val = self; /* _parent on <var_n_visibility:nullable AVisibility> */
1185 RET_LABEL1:(void)0;
1186 }
1187 }
1188 if (unlikely(var_n_kwimport == NULL)) {
1189 PRINT_ERROR("Runtime error: %s", "Cast failed");
1190 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 154);
1191 show_backtrace(1);
1192 }
1193 self->attrs[COLOR_parser_nodes__AStdImport___n_kwimport].val = var_n_kwimport; /* _n_kwimport on <self:AStdImport> */
1194 if (var_n_kwimport == NULL) {
1195 PRINT_ERROR("Runtime error: %s", "Receiver is null");
1196 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 155);
1197 show_backtrace(1);
1198 } else {
1199 { /* Inline parser_nodes#ANode#parent= (var_n_kwimport,self) on <var_n_kwimport:nullable TKwimport> */
1200 if (unlikely(var_n_kwimport == NULL)) {
1201 PRINT_ERROR("Runtime error: %s", "Receiver is null");
1202 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_nodes.nit", 38);
1203 show_backtrace(1);
1204 }
1205 var_n_kwimport->attrs[COLOR_parser_nodes__ANode___parent].val = self; /* _parent on <var_n_kwimport:nullable TKwimport> */
1206 RET_LABEL2:(void)0;
1207 }
1208 }
1209 if (unlikely(var_n_name == NULL)) {
1210 PRINT_ERROR("Runtime error: %s", "Cast failed");
1211 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 156);
1212 show_backtrace(1);
1213 }
1214 self->attrs[COLOR_parser_nodes__AStdImport___n_name].val = var_n_name; /* _n_name on <self:AStdImport> */
1215 if (var_n_name == NULL) {
1216 PRINT_ERROR("Runtime error: %s", "Receiver is null");
1217 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 157);
1218 show_backtrace(1);
1219 } else {
1220 { /* Inline parser_nodes#ANode#parent= (var_n_name,self) on <var_n_name:nullable AModuleName> */
1221 if (unlikely(var_n_name == NULL)) {
1222 PRINT_ERROR("Runtime error: %s", "Receiver is null");
1223 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_nodes.nit", 38);
1224 show_backtrace(1);
1225 }
1226 var_n_name->attrs[COLOR_parser_nodes__ANode___parent].val = self; /* _parent on <var_n_name:nullable AModuleName> */
1227 RET_LABEL3:(void)0;
1228 }
1229 }
1230 self->attrs[COLOR_parser_nodes__Prod___n_annotations].val = var_n_annotations; /* _n_annotations on <self:AStdImport> */
1231 var = NULL;
1232 if (var_n_annotations == NULL) {
1233 var4 = 0; /* is null */
1234 } else {
1235 var4 = 1; /* arg is null and recv is not */
1236 }
1237 if (0) {
1238 { /* Inline kernel#Object#!= (var_n_annotations,var) on <var_n_annotations:nullable AAnnotations> */
1239 var_other = var;
1240 {
1241 var8 = ((short int (*)(val*, val*))(var_n_annotations->class->vft[COLOR_kernel__Object___61d_61d]))(var_n_annotations, var_other) /* == on <var_n_annotations:nullable AAnnotations(AAnnotations)>*/;
1242 var7 = var8;
1243 }
1244 var9 = !var7;
1245 var5 = var9;
1246 goto RET_LABEL6;
1247 RET_LABEL6:(void)0;
1248 }
1249 var4 = var5;
1250 }
1251 if (var4){
1252 {
1253 { /* Inline parser_nodes#ANode#parent= (var_n_annotations,self) on <var_n_annotations:nullable AAnnotations(AAnnotations)> */
1254 var_n_annotations->attrs[COLOR_parser_nodes__ANode___parent].val = self; /* _parent on <var_n_annotations:nullable AAnnotations(AAnnotations)> */
1255 RET_LABEL10:(void)0;
1256 }
1257 }
1258 } else {
1259 }
1260 RET_LABEL:;
1261 }
1262 /* method parser_prod#AStdImport#init_astdimport for (self: Object, nullable AVisibility, nullable TKwimport, nullable AModuleName, nullable AAnnotations) */
1263 void VIRTUAL_parser_prod__AStdImport__init_astdimport(val* self, val* p0, val* p1, val* p2, val* p3) {
1264 parser_prod__AStdImport__init_astdimport(self, p0, p1, p2, p3); /* Direct call parser_prod#AStdImport#init_astdimport on <self:Object(AStdImport)>*/
1265 RET_LABEL:;
1266 }
1267 /* method parser_prod#AStdImport#replace_child for (self: AStdImport, ANode, nullable ANode) */
1268 void parser_prod__AStdImport__replace_child(val* self, val* p0, val* p1) {
1269 val* var_old_child /* var old_child: ANode */;
1270 val* var_new_child /* var new_child: nullable ANode */;
1271 val* var /* : AVisibility */;
1272 short int var1 /* : Bool */;
1273 short int var2 /* : Bool */;
1274 val* var_other /* var other: nullable Object */;
1275 short int var4 /* : Bool */;
1276 short int var6 /* : Bool */;
1277 short int var7 /* : Bool */;
1278 int cltype;
1279 int idtype;
1280 const char* var_class_name;
1281 val* var8 /* : TKwimport */;
1282 short int var9 /* : Bool */;
1283 short int var10 /* : Bool */;
1284 short int var12 /* : Bool */;
1285 short int var14 /* : Bool */;
1286 short int var15 /* : Bool */;
1287 int cltype16;
1288 int idtype17;
1289 const char* var_class_name18;
1290 val* var19 /* : AModuleName */;
1291 short int var20 /* : Bool */;
1292 short int var21 /* : Bool */;
1293 short int var23 /* : Bool */;
1294 short int var25 /* : Bool */;
1295 short int var26 /* : Bool */;
1296 int cltype27;
1297 int idtype28;
1298 const char* var_class_name29;
1299 val* var30 /* : nullable AAnnotations */;
1300 short int var31 /* : Bool */;
1301 short int var32 /* : Bool */;
1302 short int var34 /* : Bool */;
1303 short int var36 /* : Bool */;
1304 short int var37 /* : Bool */;
1305 int cltype38;
1306 int idtype39;
1307 const char* var_class_name40;
1308 var_old_child = p0;
1309 var_new_child = p1;
1310 var = self->attrs[COLOR_parser_nodes__AStdImport___n_visibility].val; /* _n_visibility on <self:AStdImport> */
1311 if (unlikely(var == NULL)) {
1312 PRINT_ERROR("Runtime error: %s", "Uninitialized attribute _n_visibility");
1313 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 164);
1314 show_backtrace(1);
1315 }
1316 {
1317 { /* Inline kernel#Object#== (var,var_old_child) on <var:AVisibility> */
1318 var_other = var_old_child;
1319 {
1320 { /* Inline kernel#Object#is_same_instance (var,var_other) on <var:AVisibility> */
1321 var6 = var == var_other;
1322 var4 = var6;
1323 goto RET_LABEL5;
1324 RET_LABEL5:(void)0;
1325 }
1326 }
1327 var2 = var4;
1328 goto RET_LABEL3;
1329 RET_LABEL3:(void)0;
1330 }
1331 var1 = var2;
1332 }
1333 if (var1){
1334 /* <var_new_child:nullable ANode> isa AVisibility */
1335 cltype = type_parser_nodes__AVisibility.color;
1336 idtype = type_parser_nodes__AVisibility.id;
1337 if(var_new_child == NULL) {
1338 var7 = 0;
1339 } else {
1340 if(cltype >= var_new_child->type->table_size) {
1341 var7 = 0;
1342 } else {
1343 var7 = var_new_child->type->type_table[cltype] == idtype;
1344 }
1345 }
1346 if (unlikely(!var7)) {
1347 var_class_name = var_new_child == NULL ? "null" : var_new_child->type->name;
1348 PRINT_ERROR("Runtime error: Cast failed. Expected `%s`, got `%s`", "AVisibility", var_class_name);
1349 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 165);
1350 show_backtrace(1);
1351 }
1352 {
1353 parser_prod__AStdImport__n_visibility_61d(self, var_new_child); /* Direct call parser_prod#AStdImport#n_visibility= on <self:AStdImport>*/
1354 }
1355 goto RET_LABEL;
1356 } else {
1357 }
1358 var8 = self->attrs[COLOR_parser_nodes__AStdImport___n_kwimport].val; /* _n_kwimport on <self:AStdImport> */
1359 if (unlikely(var8 == NULL)) {
1360 PRINT_ERROR("Runtime error: %s", "Uninitialized attribute _n_kwimport");
1361 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 168);
1362 show_backtrace(1);
1363 }
1364 {
1365 { /* Inline kernel#Object#== (var8,var_old_child) on <var8:TKwimport> */
1366 var_other = var_old_child;
1367 {
1368 { /* Inline kernel#Object#is_same_instance (var8,var_other) on <var8:TKwimport> */
1369 var14 = var8 == var_other;
1370 var12 = var14;
1371 goto RET_LABEL13;
1372 RET_LABEL13:(void)0;
1373 }
1374 }
1375 var10 = var12;
1376 goto RET_LABEL11;
1377 RET_LABEL11:(void)0;
1378 }
1379 var9 = var10;
1380 }
1381 if (var9){
1382 /* <var_new_child:nullable ANode> isa TKwimport */
1383 cltype16 = type_parser_nodes__TKwimport.color;
1384 idtype17 = type_parser_nodes__TKwimport.id;
1385 if(var_new_child == NULL) {
1386 var15 = 0;
1387 } else {
1388 if(cltype16 >= var_new_child->type->table_size) {
1389 var15 = 0;
1390 } else {
1391 var15 = var_new_child->type->type_table[cltype16] == idtype17;
1392 }
1393 }
1394 if (unlikely(!var15)) {
1395 var_class_name18 = var_new_child == NULL ? "null" : var_new_child->type->name;
1396 PRINT_ERROR("Runtime error: Cast failed. Expected `%s`, got `%s`", "TKwimport", var_class_name18);
1397 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 169);
1398 show_backtrace(1);
1399 }
1400 {
1401 parser_prod__AStdImport__n_kwimport_61d(self, var_new_child); /* Direct call parser_prod#AStdImport#n_kwimport= on <self:AStdImport>*/
1402 }
1403 goto RET_LABEL;
1404 } else {
1405 }
1406 var19 = self->attrs[COLOR_parser_nodes__AStdImport___n_name].val; /* _n_name on <self:AStdImport> */
1407 if (unlikely(var19 == NULL)) {
1408 PRINT_ERROR("Runtime error: %s", "Uninitialized attribute _n_name");
1409 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 172);
1410 show_backtrace(1);
1411 }
1412 {
1413 { /* Inline kernel#Object#== (var19,var_old_child) on <var19:AModuleName> */
1414 var_other = var_old_child;
1415 {
1416 { /* Inline kernel#Object#is_same_instance (var19,var_other) on <var19:AModuleName> */
1417 var25 = var19 == var_other;
1418 var23 = var25;
1419 goto RET_LABEL24;
1420 RET_LABEL24:(void)0;
1421 }
1422 }
1423 var21 = var23;
1424 goto RET_LABEL22;
1425 RET_LABEL22:(void)0;
1426 }
1427 var20 = var21;
1428 }
1429 if (var20){
1430 /* <var_new_child:nullable ANode> isa AModuleName */
1431 cltype27 = type_parser_nodes__AModuleName.color;
1432 idtype28 = type_parser_nodes__AModuleName.id;
1433 if(var_new_child == NULL) {
1434 var26 = 0;
1435 } else {
1436 if(cltype27 >= var_new_child->type->table_size) {
1437 var26 = 0;
1438 } else {
1439 var26 = var_new_child->type->type_table[cltype27] == idtype28;
1440 }
1441 }
1442 if (unlikely(!var26)) {
1443 var_class_name29 = var_new_child == NULL ? "null" : var_new_child->type->name;
1444 PRINT_ERROR("Runtime error: Cast failed. Expected `%s`, got `%s`", "AModuleName", var_class_name29);
1445 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 173);
1446 show_backtrace(1);
1447 }
1448 {
1449 parser_prod__AStdImport__n_name_61d(self, var_new_child); /* Direct call parser_prod#AStdImport#n_name= on <self:AStdImport>*/
1450 }
1451 goto RET_LABEL;
1452 } else {
1453 }
1454 var30 = self->attrs[COLOR_parser_nodes__Prod___n_annotations].val; /* _n_annotations on <self:AStdImport> */
1455 if (var30 == NULL) {
1456 var31 = 0; /* <var_old_child:ANode> cannot be null */
1457 } else {
1458 { /* Inline kernel#Object#== (var30,var_old_child) on <var30:nullable AAnnotations> */
1459 var_other = var_old_child;
1460 {
1461 { /* Inline kernel#Object#is_same_instance (var30,var_other) on <var30:nullable AAnnotations(AAnnotations)> */
1462 var36 = var30 == var_other;
1463 var34 = var36;
1464 goto RET_LABEL35;
1465 RET_LABEL35:(void)0;
1466 }
1467 }
1468 var32 = var34;
1469 goto RET_LABEL33;
1470 RET_LABEL33:(void)0;
1471 }
1472 var31 = var32;
1473 }
1474 if (var31){
1475 /* <var_new_child:nullable ANode> isa nullable AAnnotations */
1476 cltype38 = type_nullable_parser_nodes__AAnnotations.color;
1477 idtype39 = type_nullable_parser_nodes__AAnnotations.id;
1478 if(var_new_child == NULL) {
1479 var37 = 1;
1480 } else {
1481 if(cltype38 >= var_new_child->type->table_size) {
1482 var37 = 0;
1483 } else {
1484 var37 = var_new_child->type->type_table[cltype38] == idtype39;
1485 }
1486 }
1487 if (unlikely(!var37)) {
1488 var_class_name40 = var_new_child == NULL ? "null" : var_new_child->type->name;
1489 PRINT_ERROR("Runtime error: Cast failed. Expected `%s`, got `%s`", "nullable AAnnotations", var_class_name40);
1490 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 177);
1491 show_backtrace(1);
1492 }
1493 {
1494 parser_prod__AStdImport__n_annotations_61d(self, var_new_child); /* Direct call parser_prod#AStdImport#n_annotations= on <self:AStdImport>*/
1495 }
1496 goto RET_LABEL;
1497 } else {
1498 }
1499 RET_LABEL:;
1500 }
1501 /* method parser_prod#AStdImport#replace_child for (self: Object, ANode, nullable ANode) */
1502 void VIRTUAL_parser_prod__AStdImport__replace_child(val* self, val* p0, val* p1) {
1503 parser_prod__AStdImport__replace_child(self, p0, p1); /* Direct call parser_prod#AStdImport#replace_child on <self:Object(AStdImport)>*/
1504 RET_LABEL:;
1505 }
1506 /* method parser_prod#AStdImport#n_visibility= for (self: AStdImport, AVisibility) */
1507 void parser_prod__AStdImport__n_visibility_61d(val* self, val* p0) {
1508 val* var_node /* var node: AVisibility */;
1509 var_node = p0;
1510 self->attrs[COLOR_parser_nodes__AStdImport___n_visibility].val = var_node; /* _n_visibility on <self:AStdImport> */
1511 {
1512 { /* Inline parser_nodes#ANode#parent= (var_node,self) on <var_node:AVisibility> */
1513 var_node->attrs[COLOR_parser_nodes__ANode___parent].val = self; /* _parent on <var_node:AVisibility> */
1514 RET_LABEL1:(void)0;
1515 }
1516 }
1517 RET_LABEL:;
1518 }
1519 /* method parser_prod#AStdImport#n_visibility= for (self: Object, AVisibility) */
1520 void VIRTUAL_parser_prod__AStdImport__n_visibility_61d(val* self, val* p0) {
1521 parser_prod__AStdImport__n_visibility_61d(self, p0); /* Direct call parser_prod#AStdImport#n_visibility= on <self:Object(AStdImport)>*/
1522 RET_LABEL:;
1523 }
1524 /* method parser_prod#AStdImport#n_kwimport= for (self: AStdImport, TKwimport) */
1525 void parser_prod__AStdImport__n_kwimport_61d(val* self, val* p0) {
1526 val* var_node /* var node: TKwimport */;
1527 var_node = p0;
1528 self->attrs[COLOR_parser_nodes__AStdImport___n_kwimport].val = var_node; /* _n_kwimport on <self:AStdImport> */
1529 {
1530 { /* Inline parser_nodes#ANode#parent= (var_node,self) on <var_node:TKwimport> */
1531 var_node->attrs[COLOR_parser_nodes__ANode___parent].val = self; /* _parent on <var_node:TKwimport> */
1532 RET_LABEL1:(void)0;
1533 }
1534 }
1535 RET_LABEL:;
1536 }
1537 /* method parser_prod#AStdImport#n_kwimport= for (self: Object, TKwimport) */
1538 void VIRTUAL_parser_prod__AStdImport__n_kwimport_61d(val* self, val* p0) {
1539 parser_prod__AStdImport__n_kwimport_61d(self, p0); /* Direct call parser_prod#AStdImport#n_kwimport= on <self:Object(AStdImport)>*/
1540 RET_LABEL:;
1541 }
1542 /* method parser_prod#AStdImport#n_name= for (self: AStdImport, AModuleName) */
1543 void parser_prod__AStdImport__n_name_61d(val* self, val* p0) {
1544 val* var_node /* var node: AModuleName */;
1545 var_node = p0;
1546 self->attrs[COLOR_parser_nodes__AStdImport___n_name].val = var_node; /* _n_name on <self:AStdImport> */
1547 {
1548 { /* Inline parser_nodes#ANode#parent= (var_node,self) on <var_node:AModuleName> */
1549 var_node->attrs[COLOR_parser_nodes__ANode___parent].val = self; /* _parent on <var_node:AModuleName> */
1550 RET_LABEL1:(void)0;
1551 }
1552 }
1553 RET_LABEL:;
1554 }
1555 /* method parser_prod#AStdImport#n_name= for (self: Object, AModuleName) */
1556 void VIRTUAL_parser_prod__AStdImport__n_name_61d(val* self, val* p0) {
1557 parser_prod__AStdImport__n_name_61d(self, p0); /* Direct call parser_prod#AStdImport#n_name= on <self:Object(AStdImport)>*/
1558 RET_LABEL:;
1559 }
1560 /* method parser_prod#AStdImport#n_annotations= for (self: AStdImport, nullable AAnnotations) */
1561 void parser_prod__AStdImport__n_annotations_61d(val* self, val* p0) {
1562 val* var_node /* var node: nullable AAnnotations */;
1563 val* var /* : null */;
1564 short int var1 /* : Bool */;
1565 short int var2 /* : Bool */;
1566 val* var_other /* var other: nullable Object */;
1567 short int var4 /* : Bool */;
1568 short int var5 /* : Bool */;
1569 short int var6 /* : Bool */;
1570 var_node = p0;
1571 self->attrs[COLOR_parser_nodes__Prod___n_annotations].val = var_node; /* _n_annotations on <self:AStdImport> */
1572 var = NULL;
1573 if (var_node == NULL) {
1574 var1 = 0; /* is null */
1575 } else {
1576 var1 = 1; /* arg is null and recv is not */
1577 }
1578 if (0) {
1579 { /* Inline kernel#Object#!= (var_node,var) on <var_node:nullable AAnnotations> */
1580 var_other = var;
1581 {
1582 var5 = ((short int (*)(val*, val*))(var_node->class->vft[COLOR_kernel__Object___61d_61d]))(var_node, var_other) /* == on <var_node:nullable AAnnotations(AAnnotations)>*/;
1583 var4 = var5;
1584 }
1585 var6 = !var4;
1586 var2 = var6;
1587 goto RET_LABEL3;
1588 RET_LABEL3:(void)0;
1589 }
1590 var1 = var2;
1591 }
1592 if (var1){
1593 {
1594 { /* Inline parser_nodes#ANode#parent= (var_node,self) on <var_node:nullable AAnnotations(AAnnotations)> */
1595 var_node->attrs[COLOR_parser_nodes__ANode___parent].val = self; /* _parent on <var_node:nullable AAnnotations(AAnnotations)> */
1596 RET_LABEL7:(void)0;
1597 }
1598 }
1599 } else {
1600 }
1601 RET_LABEL:;
1602 }
1603 /* method parser_prod#AStdImport#n_annotations= for (self: Object, nullable AAnnotations) */
1604 void VIRTUAL_parser_prod__AStdImport__n_annotations_61d(val* self, val* p0) {
1605 parser_prod__AStdImport__n_annotations_61d(self, p0); /* Direct call parser_prod#AStdImport#n_annotations= on <self:Object(AStdImport)>*/
1606 RET_LABEL:;
1607 }
1608 /* method parser_prod#AStdImport#visit_all for (self: AStdImport, Visitor) */
1609 void parser_prod__AStdImport__visit_all(val* self, val* p0) {
1610 val* var_v /* var v: Visitor */;
1611 val* var /* : AVisibility */;
1612 val* var1 /* : TKwimport */;
1613 val* var2 /* : AModuleName */;
1614 val* var3 /* : nullable AAnnotations */;
1615 var_v = p0;
1616 var = self->attrs[COLOR_parser_nodes__AStdImport___n_visibility].val; /* _n_visibility on <self:AStdImport> */
1617 if (unlikely(var == NULL)) {
1618 PRINT_ERROR("Runtime error: %s", "Uninitialized attribute _n_visibility");
1619 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 206);
1620 show_backtrace(1);
1621 }
1622 {
1623 parser_nodes__Visitor__enter_visit(var_v, var); /* Direct call parser_nodes#Visitor#enter_visit on <var_v:Visitor>*/
1624 }
1625 var1 = self->attrs[COLOR_parser_nodes__AStdImport___n_kwimport].val; /* _n_kwimport on <self:AStdImport> */
1626 if (unlikely(var1 == NULL)) {
1627 PRINT_ERROR("Runtime error: %s", "Uninitialized attribute _n_kwimport");
1628 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 207);
1629 show_backtrace(1);
1630 }
1631 {
1632 parser_nodes__Visitor__enter_visit(var_v, var1); /* Direct call parser_nodes#Visitor#enter_visit on <var_v:Visitor>*/
1633 }
1634 var2 = self->attrs[COLOR_parser_nodes__AStdImport___n_name].val; /* _n_name on <self:AStdImport> */
1635 if (unlikely(var2 == NULL)) {
1636 PRINT_ERROR("Runtime error: %s", "Uninitialized attribute _n_name");
1637 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 208);
1638 show_backtrace(1);
1639 }
1640 {
1641 parser_nodes__Visitor__enter_visit(var_v, var2); /* Direct call parser_nodes#Visitor#enter_visit on <var_v:Visitor>*/
1642 }
1643 var3 = self->attrs[COLOR_parser_nodes__Prod___n_annotations].val; /* _n_annotations on <self:AStdImport> */
1644 {
1645 parser_nodes__Visitor__enter_visit(var_v, var3); /* Direct call parser_nodes#Visitor#enter_visit on <var_v:Visitor>*/
1646 }
1647 RET_LABEL:;
1648 }
1649 /* method parser_prod#AStdImport#visit_all for (self: Object, Visitor) */
1650 void VIRTUAL_parser_prod__AStdImport__visit_all(val* self, val* p0) {
1651 parser_prod__AStdImport__visit_all(self, p0); /* Direct call parser_prod#AStdImport#visit_all on <self:Object(AStdImport)>*/
1652 RET_LABEL:;
1653 }
1654 /* method parser_prod#ANoImport#init_anoimport for (self: ANoImport, nullable AVisibility, nullable TKwimport, nullable TKwend) */
1655 void parser_prod__ANoImport__init_anoimport(val* self, val* p0, val* p1, val* p2) {
1656 val* var_n_visibility /* var n_visibility: nullable AVisibility */;
1657 val* var_n_kwimport /* var n_kwimport: nullable TKwimport */;
1658 val* var_n_kwend /* var n_kwend: nullable TKwend */;
1659 var_n_visibility = p0;
1660 var_n_kwimport = p1;
1661 var_n_kwend = p2;
1662 if (unlikely(var_n_visibility == NULL)) {
1663 PRINT_ERROR("Runtime error: %s", "Cast failed");
1664 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 219);
1665 show_backtrace(1);
1666 }
1667 self->attrs[COLOR_parser_nodes__ANoImport___n_visibility].val = var_n_visibility; /* _n_visibility on <self:ANoImport> */
1668 if (var_n_visibility == NULL) {
1669 PRINT_ERROR("Runtime error: %s", "Receiver is null");
1670 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 220);
1671 show_backtrace(1);
1672 } else {
1673 { /* Inline parser_nodes#ANode#parent= (var_n_visibility,self) on <var_n_visibility:nullable AVisibility> */
1674 if (unlikely(var_n_visibility == NULL)) {
1675 PRINT_ERROR("Runtime error: %s", "Receiver is null");
1676 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_nodes.nit", 38);
1677 show_backtrace(1);
1678 }
1679 var_n_visibility->attrs[COLOR_parser_nodes__ANode___parent].val = self; /* _parent on <var_n_visibility:nullable AVisibility> */
1680 RET_LABEL1:(void)0;
1681 }
1682 }
1683 if (unlikely(var_n_kwimport == NULL)) {
1684 PRINT_ERROR("Runtime error: %s", "Cast failed");
1685 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 221);
1686 show_backtrace(1);
1687 }
1688 self->attrs[COLOR_parser_nodes__ANoImport___n_kwimport].val = var_n_kwimport; /* _n_kwimport on <self:ANoImport> */
1689 if (var_n_kwimport == NULL) {
1690 PRINT_ERROR("Runtime error: %s", "Receiver is null");
1691 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 222);
1692 show_backtrace(1);
1693 } else {
1694 { /* Inline parser_nodes#ANode#parent= (var_n_kwimport,self) on <var_n_kwimport:nullable TKwimport> */
1695 if (unlikely(var_n_kwimport == NULL)) {
1696 PRINT_ERROR("Runtime error: %s", "Receiver is null");
1697 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_nodes.nit", 38);
1698 show_backtrace(1);
1699 }
1700 var_n_kwimport->attrs[COLOR_parser_nodes__ANode___parent].val = self; /* _parent on <var_n_kwimport:nullable TKwimport> */
1701 RET_LABEL2:(void)0;
1702 }
1703 }
1704 if (unlikely(var_n_kwend == NULL)) {
1705 PRINT_ERROR("Runtime error: %s", "Cast failed");
1706 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 223);
1707 show_backtrace(1);
1708 }
1709 self->attrs[COLOR_parser_nodes__ANoImport___n_kwend].val = var_n_kwend; /* _n_kwend on <self:ANoImport> */
1710 if (var_n_kwend == NULL) {
1711 PRINT_ERROR("Runtime error: %s", "Receiver is null");
1712 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 224);
1713 show_backtrace(1);
1714 } else {
1715 { /* Inline parser_nodes#ANode#parent= (var_n_kwend,self) on <var_n_kwend:nullable TKwend> */
1716 if (unlikely(var_n_kwend == NULL)) {
1717 PRINT_ERROR("Runtime error: %s", "Receiver is null");
1718 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_nodes.nit", 38);
1719 show_backtrace(1);
1720 }
1721 var_n_kwend->attrs[COLOR_parser_nodes__ANode___parent].val = self; /* _parent on <var_n_kwend:nullable TKwend> */
1722 RET_LABEL3:(void)0;
1723 }
1724 }
1725 RET_LABEL:;
1726 }
1727 /* method parser_prod#ANoImport#init_anoimport for (self: Object, nullable AVisibility, nullable TKwimport, nullable TKwend) */
1728 void VIRTUAL_parser_prod__ANoImport__init_anoimport(val* self, val* p0, val* p1, val* p2) {
1729 parser_prod__ANoImport__init_anoimport(self, p0, p1, p2); /* Direct call parser_prod#ANoImport#init_anoimport on <self:Object(ANoImport)>*/
1730 RET_LABEL:;
1731 }
1732 /* method parser_prod#ANoImport#replace_child for (self: ANoImport, ANode, nullable ANode) */
1733 void parser_prod__ANoImport__replace_child(val* self, val* p0, val* p1) {
1734 val* var_old_child /* var old_child: ANode */;
1735 val* var_new_child /* var new_child: nullable ANode */;
1736 val* var /* : AVisibility */;
1737 short int var1 /* : Bool */;
1738 short int var2 /* : Bool */;
1739 val* var_other /* var other: nullable Object */;
1740 short int var4 /* : Bool */;
1741 short int var6 /* : Bool */;
1742 short int var7 /* : Bool */;
1743 int cltype;
1744 int idtype;
1745 const char* var_class_name;
1746 val* var8 /* : TKwimport */;
1747 short int var9 /* : Bool */;
1748 short int var10 /* : Bool */;
1749 short int var12 /* : Bool */;
1750 short int var14 /* : Bool */;
1751 short int var15 /* : Bool */;
1752 int cltype16;
1753 int idtype17;
1754 const char* var_class_name18;
1755 val* var19 /* : TKwend */;
1756 short int var20 /* : Bool */;
1757 short int var21 /* : Bool */;
1758 short int var23 /* : Bool */;
1759 short int var25 /* : Bool */;
1760 short int var26 /* : Bool */;
1761 int cltype27;
1762 int idtype28;
1763 const char* var_class_name29;
1764 var_old_child = p0;
1765 var_new_child = p1;
1766 var = self->attrs[COLOR_parser_nodes__ANoImport___n_visibility].val; /* _n_visibility on <self:ANoImport> */
1767 if (unlikely(var == NULL)) {
1768 PRINT_ERROR("Runtime error: %s", "Uninitialized attribute _n_visibility");
1769 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 229);
1770 show_backtrace(1);
1771 }
1772 {
1773 { /* Inline kernel#Object#== (var,var_old_child) on <var:AVisibility> */
1774 var_other = var_old_child;
1775 {
1776 { /* Inline kernel#Object#is_same_instance (var,var_other) on <var:AVisibility> */
1777 var6 = var == var_other;
1778 var4 = var6;
1779 goto RET_LABEL5;
1780 RET_LABEL5:(void)0;
1781 }
1782 }
1783 var2 = var4;
1784 goto RET_LABEL3;
1785 RET_LABEL3:(void)0;
1786 }
1787 var1 = var2;
1788 }
1789 if (var1){
1790 /* <var_new_child:nullable ANode> isa AVisibility */
1791 cltype = type_parser_nodes__AVisibility.color;
1792 idtype = type_parser_nodes__AVisibility.id;
1793 if(var_new_child == NULL) {
1794 var7 = 0;
1795 } else {
1796 if(cltype >= var_new_child->type->table_size) {
1797 var7 = 0;
1798 } else {
1799 var7 = var_new_child->type->type_table[cltype] == idtype;
1800 }
1801 }
1802 if (unlikely(!var7)) {
1803 var_class_name = var_new_child == NULL ? "null" : var_new_child->type->name;
1804 PRINT_ERROR("Runtime error: Cast failed. Expected `%s`, got `%s`", "AVisibility", var_class_name);
1805 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 230);
1806 show_backtrace(1);
1807 }
1808 {
1809 parser_prod__ANoImport__n_visibility_61d(self, var_new_child); /* Direct call parser_prod#ANoImport#n_visibility= on <self:ANoImport>*/
1810 }
1811 goto RET_LABEL;
1812 } else {
1813 }
1814 var8 = self->attrs[COLOR_parser_nodes__ANoImport___n_kwimport].val; /* _n_kwimport on <self:ANoImport> */
1815 if (unlikely(var8 == NULL)) {
1816 PRINT_ERROR("Runtime error: %s", "Uninitialized attribute _n_kwimport");
1817 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 233);
1818 show_backtrace(1);
1819 }
1820 {
1821 { /* Inline kernel#Object#== (var8,var_old_child) on <var8:TKwimport> */
1822 var_other = var_old_child;
1823 {
1824 { /* Inline kernel#Object#is_same_instance (var8,var_other) on <var8:TKwimport> */
1825 var14 = var8 == var_other;
1826 var12 = var14;
1827 goto RET_LABEL13;
1828 RET_LABEL13:(void)0;
1829 }
1830 }
1831 var10 = var12;
1832 goto RET_LABEL11;
1833 RET_LABEL11:(void)0;
1834 }
1835 var9 = var10;
1836 }
1837 if (var9){
1838 /* <var_new_child:nullable ANode> isa TKwimport */
1839 cltype16 = type_parser_nodes__TKwimport.color;
1840 idtype17 = type_parser_nodes__TKwimport.id;
1841 if(var_new_child == NULL) {
1842 var15 = 0;
1843 } else {
1844 if(cltype16 >= var_new_child->type->table_size) {
1845 var15 = 0;
1846 } else {
1847 var15 = var_new_child->type->type_table[cltype16] == idtype17;
1848 }
1849 }
1850 if (unlikely(!var15)) {
1851 var_class_name18 = var_new_child == NULL ? "null" : var_new_child->type->name;
1852 PRINT_ERROR("Runtime error: Cast failed. Expected `%s`, got `%s`", "TKwimport", var_class_name18);
1853 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 234);
1854 show_backtrace(1);
1855 }
1856 {
1857 parser_prod__ANoImport__n_kwimport_61d(self, var_new_child); /* Direct call parser_prod#ANoImport#n_kwimport= on <self:ANoImport>*/
1858 }
1859 goto RET_LABEL;
1860 } else {
1861 }
1862 var19 = self->attrs[COLOR_parser_nodes__ANoImport___n_kwend].val; /* _n_kwend on <self:ANoImport> */
1863 if (unlikely(var19 == NULL)) {
1864 PRINT_ERROR("Runtime error: %s", "Uninitialized attribute _n_kwend");
1865 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 237);
1866 show_backtrace(1);
1867 }
1868 {
1869 { /* Inline kernel#Object#== (var19,var_old_child) on <var19:TKwend> */
1870 var_other = var_old_child;
1871 {
1872 { /* Inline kernel#Object#is_same_instance (var19,var_other) on <var19:TKwend> */
1873 var25 = var19 == var_other;
1874 var23 = var25;
1875 goto RET_LABEL24;
1876 RET_LABEL24:(void)0;
1877 }
1878 }
1879 var21 = var23;
1880 goto RET_LABEL22;
1881 RET_LABEL22:(void)0;
1882 }
1883 var20 = var21;
1884 }
1885 if (var20){
1886 /* <var_new_child:nullable ANode> isa TKwend */
1887 cltype27 = type_parser_nodes__TKwend.color;
1888 idtype28 = type_parser_nodes__TKwend.id;
1889 if(var_new_child == NULL) {
1890 var26 = 0;
1891 } else {
1892 if(cltype27 >= var_new_child->type->table_size) {
1893 var26 = 0;
1894 } else {
1895 var26 = var_new_child->type->type_table[cltype27] == idtype28;
1896 }
1897 }
1898 if (unlikely(!var26)) {
1899 var_class_name29 = var_new_child == NULL ? "null" : var_new_child->type->name;
1900 PRINT_ERROR("Runtime error: Cast failed. Expected `%s`, got `%s`", "TKwend", var_class_name29);
1901 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 238);
1902 show_backtrace(1);
1903 }
1904 {
1905 parser_prod__ANoImport__n_kwend_61d(self, var_new_child); /* Direct call parser_prod#ANoImport#n_kwend= on <self:ANoImport>*/
1906 }
1907 goto RET_LABEL;
1908 } else {
1909 }
1910 RET_LABEL:;
1911 }
1912 /* method parser_prod#ANoImport#replace_child for (self: Object, ANode, nullable ANode) */
1913 void VIRTUAL_parser_prod__ANoImport__replace_child(val* self, val* p0, val* p1) {
1914 parser_prod__ANoImport__replace_child(self, p0, p1); /* Direct call parser_prod#ANoImport#replace_child on <self:Object(ANoImport)>*/
1915 RET_LABEL:;
1916 }
1917 /* method parser_prod#ANoImport#n_visibility= for (self: ANoImport, AVisibility) */
1918 void parser_prod__ANoImport__n_visibility_61d(val* self, val* p0) {
1919 val* var_node /* var node: AVisibility */;
1920 var_node = p0;
1921 self->attrs[COLOR_parser_nodes__ANoImport___n_visibility].val = var_node; /* _n_visibility on <self:ANoImport> */
1922 {
1923 { /* Inline parser_nodes#ANode#parent= (var_node,self) on <var_node:AVisibility> */
1924 var_node->attrs[COLOR_parser_nodes__ANode___parent].val = self; /* _parent on <var_node:AVisibility> */
1925 RET_LABEL1:(void)0;
1926 }
1927 }
1928 RET_LABEL:;
1929 }
1930 /* method parser_prod#ANoImport#n_visibility= for (self: Object, AVisibility) */
1931 void VIRTUAL_parser_prod__ANoImport__n_visibility_61d(val* self, val* p0) {
1932 parser_prod__ANoImport__n_visibility_61d(self, p0); /* Direct call parser_prod#ANoImport#n_visibility= on <self:Object(ANoImport)>*/
1933 RET_LABEL:;
1934 }
1935 /* method parser_prod#ANoImport#n_kwimport= for (self: ANoImport, TKwimport) */
1936 void parser_prod__ANoImport__n_kwimport_61d(val* self, val* p0) {
1937 val* var_node /* var node: TKwimport */;
1938 var_node = p0;
1939 self->attrs[COLOR_parser_nodes__ANoImport___n_kwimport].val = var_node; /* _n_kwimport on <self:ANoImport> */
1940 {
1941 { /* Inline parser_nodes#ANode#parent= (var_node,self) on <var_node:TKwimport> */
1942 var_node->attrs[COLOR_parser_nodes__ANode___parent].val = self; /* _parent on <var_node:TKwimport> */
1943 RET_LABEL1:(void)0;
1944 }
1945 }
1946 RET_LABEL:;
1947 }
1948 /* method parser_prod#ANoImport#n_kwimport= for (self: Object, TKwimport) */
1949 void VIRTUAL_parser_prod__ANoImport__n_kwimport_61d(val* self, val* p0) {
1950 parser_prod__ANoImport__n_kwimport_61d(self, p0); /* Direct call parser_prod#ANoImport#n_kwimport= on <self:Object(ANoImport)>*/
1951 RET_LABEL:;
1952 }
1953 /* method parser_prod#ANoImport#n_kwend= for (self: ANoImport, TKwend) */
1954 void parser_prod__ANoImport__n_kwend_61d(val* self, val* p0) {
1955 val* var_node /* var node: TKwend */;
1956 var_node = p0;
1957 self->attrs[COLOR_parser_nodes__ANoImport___n_kwend].val = var_node; /* _n_kwend on <self:ANoImport> */
1958 {
1959 { /* Inline parser_nodes#ANode#parent= (var_node,self) on <var_node:TKwend> */
1960 var_node->attrs[COLOR_parser_nodes__ANode___parent].val = self; /* _parent on <var_node:TKwend> */
1961 RET_LABEL1:(void)0;
1962 }
1963 }
1964 RET_LABEL:;
1965 }
1966 /* method parser_prod#ANoImport#n_kwend= for (self: Object, TKwend) */
1967 void VIRTUAL_parser_prod__ANoImport__n_kwend_61d(val* self, val* p0) {
1968 parser_prod__ANoImport__n_kwend_61d(self, p0); /* Direct call parser_prod#ANoImport#n_kwend= on <self:Object(ANoImport)>*/
1969 RET_LABEL:;
1970 }
1971 /* method parser_prod#ANoImport#visit_all for (self: ANoImport, Visitor) */
1972 void parser_prod__ANoImport__visit_all(val* self, val* p0) {
1973 val* var_v /* var v: Visitor */;
1974 val* var /* : AVisibility */;
1975 val* var1 /* : TKwimport */;
1976 val* var2 /* : TKwend */;
1977 var_v = p0;
1978 var = self->attrs[COLOR_parser_nodes__ANoImport___n_visibility].val; /* _n_visibility on <self:ANoImport> */
1979 if (unlikely(var == NULL)) {
1980 PRINT_ERROR("Runtime error: %s", "Uninitialized attribute _n_visibility");
1981 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 262);
1982 show_backtrace(1);
1983 }
1984 {
1985 parser_nodes__Visitor__enter_visit(var_v, var); /* Direct call parser_nodes#Visitor#enter_visit on <var_v:Visitor>*/
1986 }
1987 var1 = self->attrs[COLOR_parser_nodes__ANoImport___n_kwimport].val; /* _n_kwimport on <self:ANoImport> */
1988 if (unlikely(var1 == NULL)) {
1989 PRINT_ERROR("Runtime error: %s", "Uninitialized attribute _n_kwimport");
1990 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 263);
1991 show_backtrace(1);
1992 }
1993 {
1994 parser_nodes__Visitor__enter_visit(var_v, var1); /* Direct call parser_nodes#Visitor#enter_visit on <var_v:Visitor>*/
1995 }
1996 var2 = self->attrs[COLOR_parser_nodes__ANoImport___n_kwend].val; /* _n_kwend on <self:ANoImport> */
1997 if (unlikely(var2 == NULL)) {
1998 PRINT_ERROR("Runtime error: %s", "Uninitialized attribute _n_kwend");
1999 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 264);
2000 show_backtrace(1);
2001 }
2002 {
2003 parser_nodes__Visitor__enter_visit(var_v, var2); /* Direct call parser_nodes#Visitor#enter_visit on <var_v:Visitor>*/
2004 }
2005 RET_LABEL:;
2006 }
2007 /* method parser_prod#ANoImport#visit_all for (self: Object, Visitor) */
2008 void VIRTUAL_parser_prod__ANoImport__visit_all(val* self, val* p0) {
2009 parser_prod__ANoImport__visit_all(self, p0); /* Direct call parser_prod#ANoImport#visit_all on <self:Object(ANoImport)>*/
2010 RET_LABEL:;
2011 }
2012 /* method parser_prod#APublicVisibility#init_apublicvisibility for (self: APublicVisibility, nullable TKwpublic) */
2013 void parser_prod__APublicVisibility__init_apublicvisibility(val* self, val* p0) {
2014 val* var_n_kwpublic /* var n_kwpublic: nullable TKwpublic */;
2015 val* var /* : null */;
2016 short int var1 /* : Bool */;
2017 short int var2 /* : Bool */;
2018 val* var_other /* var other: nullable Object */;
2019 short int var4 /* : Bool */;
2020 short int var5 /* : Bool */;
2021 short int var6 /* : Bool */;
2022 var_n_kwpublic = p0;
2023 self->attrs[COLOR_parser_nodes__APublicVisibility___n_kwpublic].val = var_n_kwpublic; /* _n_kwpublic on <self:APublicVisibility> */
2024 var = NULL;
2025 if (var_n_kwpublic == NULL) {
2026 var1 = 0; /* is null */
2027 } else {
2028 var1 = 1; /* arg is null and recv is not */
2029 }
2030 if (0) {
2031 { /* Inline kernel#Object#!= (var_n_kwpublic,var) on <var_n_kwpublic:nullable TKwpublic> */
2032 var_other = var;
2033 {
2034 var5 = ((short int (*)(val*, val*))(var_n_kwpublic->class->vft[COLOR_kernel__Object___61d_61d]))(var_n_kwpublic, var_other) /* == on <var_n_kwpublic:nullable TKwpublic(TKwpublic)>*/;
2035 var4 = var5;
2036 }
2037 var6 = !var4;
2038 var2 = var6;
2039 goto RET_LABEL3;
2040 RET_LABEL3:(void)0;
2041 }
2042 var1 = var2;
2043 }
2044 if (var1){
2045 {
2046 { /* Inline parser_nodes#ANode#parent= (var_n_kwpublic,self) on <var_n_kwpublic:nullable TKwpublic(TKwpublic)> */
2047 var_n_kwpublic->attrs[COLOR_parser_nodes__ANode___parent].val = self; /* _parent on <var_n_kwpublic:nullable TKwpublic(TKwpublic)> */
2048 RET_LABEL7:(void)0;
2049 }
2050 }
2051 } else {
2052 }
2053 RET_LABEL:;
2054 }
2055 /* method parser_prod#APublicVisibility#init_apublicvisibility for (self: Object, nullable TKwpublic) */
2056 void VIRTUAL_parser_prod__APublicVisibility__init_apublicvisibility(val* self, val* p0) {
2057 parser_prod__APublicVisibility__init_apublicvisibility(self, p0); /* Direct call parser_prod#APublicVisibility#init_apublicvisibility on <self:Object(APublicVisibility)>*/
2058 RET_LABEL:;
2059 }
2060 /* method parser_prod#APublicVisibility#replace_child for (self: APublicVisibility, ANode, nullable ANode) */
2061 void parser_prod__APublicVisibility__replace_child(val* self, val* p0, val* p1) {
2062 val* var_old_child /* var old_child: ANode */;
2063 val* var_new_child /* var new_child: nullable ANode */;
2064 val* var /* : nullable TKwpublic */;
2065 short int var1 /* : Bool */;
2066 short int var2 /* : Bool */;
2067 val* var_other /* var other: nullable Object */;
2068 short int var4 /* : Bool */;
2069 short int var6 /* : Bool */;
2070 short int var7 /* : Bool */;
2071 int cltype;
2072 int idtype;
2073 const char* var_class_name;
2074 var_old_child = p0;
2075 var_new_child = p1;
2076 var = self->attrs[COLOR_parser_nodes__APublicVisibility___n_kwpublic].val; /* _n_kwpublic on <self:APublicVisibility> */
2077 if (var == NULL) {
2078 var1 = 0; /* <var_old_child:ANode> cannot be null */
2079 } else {
2080 { /* Inline kernel#Object#== (var,var_old_child) on <var:nullable TKwpublic> */
2081 var_other = var_old_child;
2082 {
2083 { /* Inline kernel#Object#is_same_instance (var,var_other) on <var:nullable TKwpublic(TKwpublic)> */
2084 var6 = var == var_other;
2085 var4 = var6;
2086 goto RET_LABEL5;
2087 RET_LABEL5:(void)0;
2088 }
2089 }
2090 var2 = var4;
2091 goto RET_LABEL3;
2092 RET_LABEL3:(void)0;
2093 }
2094 var1 = var2;
2095 }
2096 if (var1){
2097 /* <var_new_child:nullable ANode> isa nullable TKwpublic */
2098 cltype = type_nullable_parser_nodes__TKwpublic.color;
2099 idtype = type_nullable_parser_nodes__TKwpublic.id;
2100 if(var_new_child == NULL) {
2101 var7 = 1;
2102 } else {
2103 if(cltype >= var_new_child->type->table_size) {
2104 var7 = 0;
2105 } else {
2106 var7 = var_new_child->type->type_table[cltype] == idtype;
2107 }
2108 }
2109 if (unlikely(!var7)) {
2110 var_class_name = var_new_child == NULL ? "null" : var_new_child->type->name;
2111 PRINT_ERROR("Runtime error: Cast failed. Expected `%s`, got `%s`", "nullable TKwpublic", var_class_name);
2112 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 279);
2113 show_backtrace(1);
2114 }
2115 {
2116 parser_prod__APublicVisibility__n_kwpublic_61d(self, var_new_child); /* Direct call parser_prod#APublicVisibility#n_kwpublic= on <self:APublicVisibility>*/
2117 }
2118 goto RET_LABEL;
2119 } else {
2120 }
2121 RET_LABEL:;
2122 }
2123 /* method parser_prod#APublicVisibility#replace_child for (self: Object, ANode, nullable ANode) */
2124 void VIRTUAL_parser_prod__APublicVisibility__replace_child(val* self, val* p0, val* p1) {
2125 parser_prod__APublicVisibility__replace_child(self, p0, p1); /* Direct call parser_prod#APublicVisibility#replace_child on <self:Object(APublicVisibility)>*/
2126 RET_LABEL:;
2127 }
2128 /* method parser_prod#APublicVisibility#n_kwpublic= for (self: APublicVisibility, nullable TKwpublic) */
2129 void parser_prod__APublicVisibility__n_kwpublic_61d(val* self, val* p0) {
2130 val* var_node /* var node: nullable TKwpublic */;
2131 val* var /* : null */;
2132 short int var1 /* : Bool */;
2133 short int var2 /* : Bool */;
2134 val* var_other /* var other: nullable Object */;
2135 short int var4 /* : Bool */;
2136 short int var5 /* : Bool */;
2137 short int var6 /* : Bool */;
2138 var_node = p0;
2139 self->attrs[COLOR_parser_nodes__APublicVisibility___n_kwpublic].val = var_node; /* _n_kwpublic on <self:APublicVisibility> */
2140 var = NULL;
2141 if (var_node == NULL) {
2142 var1 = 0; /* is null */
2143 } else {
2144 var1 = 1; /* arg is null and recv is not */
2145 }
2146 if (0) {
2147 { /* Inline kernel#Object#!= (var_node,var) on <var_node:nullable TKwpublic> */
2148 var_other = var;
2149 {
2150 var5 = ((short int (*)(val*, val*))(var_node->class->vft[COLOR_kernel__Object___61d_61d]))(var_node, var_other) /* == on <var_node:nullable TKwpublic(TKwpublic)>*/;
2151 var4 = var5;
2152 }
2153 var6 = !var4;
2154 var2 = var6;
2155 goto RET_LABEL3;
2156 RET_LABEL3:(void)0;
2157 }
2158 var1 = var2;
2159 }
2160 if (var1){
2161 {
2162 { /* Inline parser_nodes#ANode#parent= (var_node,self) on <var_node:nullable TKwpublic(TKwpublic)> */
2163 var_node->attrs[COLOR_parser_nodes__ANode___parent].val = self; /* _parent on <var_node:nullable TKwpublic(TKwpublic)> */
2164 RET_LABEL7:(void)0;
2165 }
2166 }
2167 } else {
2168 }
2169 RET_LABEL:;
2170 }
2171 /* method parser_prod#APublicVisibility#n_kwpublic= for (self: Object, nullable TKwpublic) */
2172 void VIRTUAL_parser_prod__APublicVisibility__n_kwpublic_61d(val* self, val* p0) {
2173 parser_prod__APublicVisibility__n_kwpublic_61d(self, p0); /* Direct call parser_prod#APublicVisibility#n_kwpublic= on <self:Object(APublicVisibility)>*/
2174 RET_LABEL:;
2175 }
2176 /* method parser_prod#APublicVisibility#visit_all for (self: APublicVisibility, Visitor) */
2177 void parser_prod__APublicVisibility__visit_all(val* self, val* p0) {
2178 val* var_v /* var v: Visitor */;
2179 val* var /* : nullable TKwpublic */;
2180 var_v = p0;
2181 var = self->attrs[COLOR_parser_nodes__APublicVisibility___n_kwpublic].val; /* _n_kwpublic on <self:APublicVisibility> */
2182 {
2183 parser_nodes__Visitor__enter_visit(var_v, var); /* Direct call parser_nodes#Visitor#enter_visit on <var_v:Visitor>*/
2184 }
2185 RET_LABEL:;
2186 }
2187 /* method parser_prod#APublicVisibility#visit_all for (self: Object, Visitor) */
2188 void VIRTUAL_parser_prod__APublicVisibility__visit_all(val* self, val* p0) {
2189 parser_prod__APublicVisibility__visit_all(self, p0); /* Direct call parser_prod#APublicVisibility#visit_all on <self:Object(APublicVisibility)>*/
2190 RET_LABEL:;
2191 }
2192 /* method parser_prod#APrivateVisibility#init_aprivatevisibility for (self: APrivateVisibility, nullable TKwprivate) */
2193 void parser_prod__APrivateVisibility__init_aprivatevisibility(val* self, val* p0) {
2194 val* var_n_kwprivate /* var n_kwprivate: nullable TKwprivate */;
2195 var_n_kwprivate = p0;
2196 if (unlikely(var_n_kwprivate == NULL)) {
2197 PRINT_ERROR("Runtime error: %s", "Cast failed");
2198 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 301);
2199 show_backtrace(1);
2200 }
2201 self->attrs[COLOR_parser_nodes__APrivateVisibility___n_kwprivate].val = var_n_kwprivate; /* _n_kwprivate on <self:APrivateVisibility> */
2202 if (var_n_kwprivate == NULL) {
2203 PRINT_ERROR("Runtime error: %s", "Receiver is null");
2204 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 302);
2205 show_backtrace(1);
2206 } else {
2207 { /* Inline parser_nodes#ANode#parent= (var_n_kwprivate,self) on <var_n_kwprivate:nullable TKwprivate> */
2208 if (unlikely(var_n_kwprivate == NULL)) {
2209 PRINT_ERROR("Runtime error: %s", "Receiver is null");
2210 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_nodes.nit", 38);
2211 show_backtrace(1);
2212 }
2213 var_n_kwprivate->attrs[COLOR_parser_nodes__ANode___parent].val = self; /* _parent on <var_n_kwprivate:nullable TKwprivate> */
2214 RET_LABEL1:(void)0;
2215 }
2216 }
2217 RET_LABEL:;
2218 }
2219 /* method parser_prod#APrivateVisibility#init_aprivatevisibility for (self: Object, nullable TKwprivate) */
2220 void VIRTUAL_parser_prod__APrivateVisibility__init_aprivatevisibility(val* self, val* p0) {
2221 parser_prod__APrivateVisibility__init_aprivatevisibility(self, p0); /* Direct call parser_prod#APrivateVisibility#init_aprivatevisibility on <self:Object(APrivateVisibility)>*/
2222 RET_LABEL:;
2223 }
2224 /* method parser_prod#APrivateVisibility#replace_child for (self: APrivateVisibility, ANode, nullable ANode) */
2225 void parser_prod__APrivateVisibility__replace_child(val* self, val* p0, val* p1) {
2226 val* var_old_child /* var old_child: ANode */;
2227 val* var_new_child /* var new_child: nullable ANode */;
2228 val* var /* : TKwprivate */;
2229 short int var1 /* : Bool */;
2230 short int var2 /* : Bool */;
2231 val* var_other /* var other: nullable Object */;
2232 short int var4 /* : Bool */;
2233 short int var6 /* : Bool */;
2234 short int var7 /* : Bool */;
2235 int cltype;
2236 int idtype;
2237 const char* var_class_name;
2238 var_old_child = p0;
2239 var_new_child = p1;
2240 var = self->attrs[COLOR_parser_nodes__APrivateVisibility___n_kwprivate].val; /* _n_kwprivate on <self:APrivateVisibility> */
2241 if (unlikely(var == NULL)) {
2242 PRINT_ERROR("Runtime error: %s", "Uninitialized attribute _n_kwprivate");
2243 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 307);
2244 show_backtrace(1);
2245 }
2246 {
2247 { /* Inline kernel#Object#== (var,var_old_child) on <var:TKwprivate> */
2248 var_other = var_old_child;
2249 {
2250 { /* Inline kernel#Object#is_same_instance (var,var_other) on <var:TKwprivate> */
2251 var6 = var == var_other;
2252 var4 = var6;
2253 goto RET_LABEL5;
2254 RET_LABEL5:(void)0;
2255 }
2256 }
2257 var2 = var4;
2258 goto RET_LABEL3;
2259 RET_LABEL3:(void)0;
2260 }
2261 var1 = var2;
2262 }
2263 if (var1){
2264 /* <var_new_child:nullable ANode> isa TKwprivate */
2265 cltype = type_parser_nodes__TKwprivate.color;
2266 idtype = type_parser_nodes__TKwprivate.id;
2267 if(var_new_child == NULL) {
2268 var7 = 0;
2269 } else {
2270 if(cltype >= var_new_child->type->table_size) {
2271 var7 = 0;
2272 } else {
2273 var7 = var_new_child->type->type_table[cltype] == idtype;
2274 }
2275 }
2276 if (unlikely(!var7)) {
2277 var_class_name = var_new_child == NULL ? "null" : var_new_child->type->name;
2278 PRINT_ERROR("Runtime error: Cast failed. Expected `%s`, got `%s`", "TKwprivate", var_class_name);
2279 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 308);
2280 show_backtrace(1);
2281 }
2282 {
2283 parser_prod__APrivateVisibility__n_kwprivate_61d(self, var_new_child); /* Direct call parser_prod#APrivateVisibility#n_kwprivate= on <self:APrivateVisibility>*/
2284 }
2285 goto RET_LABEL;
2286 } else {
2287 }
2288 RET_LABEL:;
2289 }
2290 /* method parser_prod#APrivateVisibility#replace_child for (self: Object, ANode, nullable ANode) */
2291 void VIRTUAL_parser_prod__APrivateVisibility__replace_child(val* self, val* p0, val* p1) {
2292 parser_prod__APrivateVisibility__replace_child(self, p0, p1); /* Direct call parser_prod#APrivateVisibility#replace_child on <self:Object(APrivateVisibility)>*/
2293 RET_LABEL:;
2294 }
2295 /* method parser_prod#APrivateVisibility#n_kwprivate= for (self: APrivateVisibility, TKwprivate) */
2296 void parser_prod__APrivateVisibility__n_kwprivate_61d(val* self, val* p0) {
2297 val* var_node /* var node: TKwprivate */;
2298 var_node = p0;
2299 self->attrs[COLOR_parser_nodes__APrivateVisibility___n_kwprivate].val = var_node; /* _n_kwprivate on <self:APrivateVisibility> */
2300 {
2301 { /* Inline parser_nodes#ANode#parent= (var_node,self) on <var_node:TKwprivate> */
2302 var_node->attrs[COLOR_parser_nodes__ANode___parent].val = self; /* _parent on <var_node:TKwprivate> */
2303 RET_LABEL1:(void)0;
2304 }
2305 }
2306 RET_LABEL:;
2307 }
2308 /* method parser_prod#APrivateVisibility#n_kwprivate= for (self: Object, TKwprivate) */
2309 void VIRTUAL_parser_prod__APrivateVisibility__n_kwprivate_61d(val* self, val* p0) {
2310 parser_prod__APrivateVisibility__n_kwprivate_61d(self, p0); /* Direct call parser_prod#APrivateVisibility#n_kwprivate= on <self:Object(APrivateVisibility)>*/
2311 RET_LABEL:;
2312 }
2313 /* method parser_prod#APrivateVisibility#visit_all for (self: APrivateVisibility, Visitor) */
2314 void parser_prod__APrivateVisibility__visit_all(val* self, val* p0) {
2315 val* var_v /* var v: Visitor */;
2316 val* var /* : TKwprivate */;
2317 var_v = p0;
2318 var = self->attrs[COLOR_parser_nodes__APrivateVisibility___n_kwprivate].val; /* _n_kwprivate on <self:APrivateVisibility> */
2319 if (unlikely(var == NULL)) {
2320 PRINT_ERROR("Runtime error: %s", "Uninitialized attribute _n_kwprivate");
2321 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 322);
2322 show_backtrace(1);
2323 }
2324 {
2325 parser_nodes__Visitor__enter_visit(var_v, var); /* Direct call parser_nodes#Visitor#enter_visit on <var_v:Visitor>*/
2326 }
2327 RET_LABEL:;
2328 }
2329 /* method parser_prod#APrivateVisibility#visit_all for (self: Object, Visitor) */
2330 void VIRTUAL_parser_prod__APrivateVisibility__visit_all(val* self, val* p0) {
2331 parser_prod__APrivateVisibility__visit_all(self, p0); /* Direct call parser_prod#APrivateVisibility#visit_all on <self:Object(APrivateVisibility)>*/
2332 RET_LABEL:;
2333 }
2334 /* method parser_prod#AProtectedVisibility#init_aprotectedvisibility for (self: AProtectedVisibility, nullable TKwprotected) */
2335 void parser_prod__AProtectedVisibility__init_aprotectedvisibility(val* self, val* p0) {
2336 val* var_n_kwprotected /* var n_kwprotected: nullable TKwprotected */;
2337 var_n_kwprotected = p0;
2338 if (unlikely(var_n_kwprotected == NULL)) {
2339 PRINT_ERROR("Runtime error: %s", "Cast failed");
2340 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 330);
2341 show_backtrace(1);
2342 }
2343 self->attrs[COLOR_parser_nodes__AProtectedVisibility___n_kwprotected].val = var_n_kwprotected; /* _n_kwprotected on <self:AProtectedVisibility> */
2344 if (var_n_kwprotected == NULL) {
2345 PRINT_ERROR("Runtime error: %s", "Receiver is null");
2346 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 331);
2347 show_backtrace(1);
2348 } else {
2349 { /* Inline parser_nodes#ANode#parent= (var_n_kwprotected,self) on <var_n_kwprotected:nullable TKwprotected> */
2350 if (unlikely(var_n_kwprotected == NULL)) {
2351 PRINT_ERROR("Runtime error: %s", "Receiver is null");
2352 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_nodes.nit", 38);
2353 show_backtrace(1);
2354 }
2355 var_n_kwprotected->attrs[COLOR_parser_nodes__ANode___parent].val = self; /* _parent on <var_n_kwprotected:nullable TKwprotected> */
2356 RET_LABEL1:(void)0;
2357 }
2358 }
2359 RET_LABEL:;
2360 }
2361 /* method parser_prod#AProtectedVisibility#init_aprotectedvisibility for (self: Object, nullable TKwprotected) */
2362 void VIRTUAL_parser_prod__AProtectedVisibility__init_aprotectedvisibility(val* self, val* p0) {
2363 parser_prod__AProtectedVisibility__init_aprotectedvisibility(self, p0); /* Direct call parser_prod#AProtectedVisibility#init_aprotectedvisibility on <self:Object(AProtectedVisibility)>*/
2364 RET_LABEL:;
2365 }
2366 /* method parser_prod#AProtectedVisibility#replace_child for (self: AProtectedVisibility, ANode, nullable ANode) */
2367 void parser_prod__AProtectedVisibility__replace_child(val* self, val* p0, val* p1) {
2368 val* var_old_child /* var old_child: ANode */;
2369 val* var_new_child /* var new_child: nullable ANode */;
2370 val* var /* : TKwprotected */;
2371 short int var1 /* : Bool */;
2372 short int var2 /* : Bool */;
2373 val* var_other /* var other: nullable Object */;
2374 short int var4 /* : Bool */;
2375 short int var6 /* : Bool */;
2376 short int var7 /* : Bool */;
2377 int cltype;
2378 int idtype;
2379 const char* var_class_name;
2380 var_old_child = p0;
2381 var_new_child = p1;
2382 var = self->attrs[COLOR_parser_nodes__AProtectedVisibility___n_kwprotected].val; /* _n_kwprotected on <self:AProtectedVisibility> */
2383 if (unlikely(var == NULL)) {
2384 PRINT_ERROR("Runtime error: %s", "Uninitialized attribute _n_kwprotected");
2385 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 336);
2386 show_backtrace(1);
2387 }
2388 {
2389 { /* Inline kernel#Object#== (var,var_old_child) on <var:TKwprotected> */
2390 var_other = var_old_child;
2391 {
2392 { /* Inline kernel#Object#is_same_instance (var,var_other) on <var:TKwprotected> */
2393 var6 = var == var_other;
2394 var4 = var6;
2395 goto RET_LABEL5;
2396 RET_LABEL5:(void)0;
2397 }
2398 }
2399 var2 = var4;
2400 goto RET_LABEL3;
2401 RET_LABEL3:(void)0;
2402 }
2403 var1 = var2;
2404 }
2405 if (var1){
2406 /* <var_new_child:nullable ANode> isa TKwprotected */
2407 cltype = type_parser_nodes__TKwprotected.color;
2408 idtype = type_parser_nodes__TKwprotected.id;
2409 if(var_new_child == NULL) {
2410 var7 = 0;
2411 } else {
2412 if(cltype >= var_new_child->type->table_size) {
2413 var7 = 0;
2414 } else {
2415 var7 = var_new_child->type->type_table[cltype] == idtype;
2416 }
2417 }
2418 if (unlikely(!var7)) {
2419 var_class_name = var_new_child == NULL ? "null" : var_new_child->type->name;
2420 PRINT_ERROR("Runtime error: Cast failed. Expected `%s`, got `%s`", "TKwprotected", var_class_name);
2421 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 337);
2422 show_backtrace(1);
2423 }
2424 {
2425 parser_prod__AProtectedVisibility__n_kwprotected_61d(self, var_new_child); /* Direct call parser_prod#AProtectedVisibility#n_kwprotected= on <self:AProtectedVisibility>*/
2426 }
2427 goto RET_LABEL;
2428 } else {
2429 }
2430 RET_LABEL:;
2431 }
2432 /* method parser_prod#AProtectedVisibility#replace_child for (self: Object, ANode, nullable ANode) */
2433 void VIRTUAL_parser_prod__AProtectedVisibility__replace_child(val* self, val* p0, val* p1) {
2434 parser_prod__AProtectedVisibility__replace_child(self, p0, p1); /* Direct call parser_prod#AProtectedVisibility#replace_child on <self:Object(AProtectedVisibility)>*/
2435 RET_LABEL:;
2436 }
2437 /* method parser_prod#AProtectedVisibility#n_kwprotected= for (self: AProtectedVisibility, TKwprotected) */
2438 void parser_prod__AProtectedVisibility__n_kwprotected_61d(val* self, val* p0) {
2439 val* var_node /* var node: TKwprotected */;
2440 var_node = p0;
2441 self->attrs[COLOR_parser_nodes__AProtectedVisibility___n_kwprotected].val = var_node; /* _n_kwprotected on <self:AProtectedVisibility> */
2442 {
2443 { /* Inline parser_nodes#ANode#parent= (var_node,self) on <var_node:TKwprotected> */
2444 var_node->attrs[COLOR_parser_nodes__ANode___parent].val = self; /* _parent on <var_node:TKwprotected> */
2445 RET_LABEL1:(void)0;
2446 }
2447 }
2448 RET_LABEL:;
2449 }
2450 /* method parser_prod#AProtectedVisibility#n_kwprotected= for (self: Object, TKwprotected) */
2451 void VIRTUAL_parser_prod__AProtectedVisibility__n_kwprotected_61d(val* self, val* p0) {
2452 parser_prod__AProtectedVisibility__n_kwprotected_61d(self, p0); /* Direct call parser_prod#AProtectedVisibility#n_kwprotected= on <self:Object(AProtectedVisibility)>*/
2453 RET_LABEL:;
2454 }
2455 /* method parser_prod#AProtectedVisibility#visit_all for (self: AProtectedVisibility, Visitor) */
2456 void parser_prod__AProtectedVisibility__visit_all(val* self, val* p0) {
2457 val* var_v /* var v: Visitor */;
2458 val* var /* : TKwprotected */;
2459 var_v = p0;
2460 var = self->attrs[COLOR_parser_nodes__AProtectedVisibility___n_kwprotected].val; /* _n_kwprotected on <self:AProtectedVisibility> */
2461 if (unlikely(var == NULL)) {
2462 PRINT_ERROR("Runtime error: %s", "Uninitialized attribute _n_kwprotected");
2463 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 351);
2464 show_backtrace(1);
2465 }
2466 {
2467 parser_nodes__Visitor__enter_visit(var_v, var); /* Direct call parser_nodes#Visitor#enter_visit on <var_v:Visitor>*/
2468 }
2469 RET_LABEL:;
2470 }
2471 /* method parser_prod#AProtectedVisibility#visit_all for (self: Object, Visitor) */
2472 void VIRTUAL_parser_prod__AProtectedVisibility__visit_all(val* self, val* p0) {
2473 parser_prod__AProtectedVisibility__visit_all(self, p0); /* Direct call parser_prod#AProtectedVisibility#visit_all on <self:Object(AProtectedVisibility)>*/
2474 RET_LABEL:;
2475 }
2476 /* method parser_prod#AIntrudeVisibility#init_aintrudevisibility for (self: AIntrudeVisibility, nullable TKwintrude) */
2477 void parser_prod__AIntrudeVisibility__init_aintrudevisibility(val* self, val* p0) {
2478 val* var_n_kwintrude /* var n_kwintrude: nullable TKwintrude */;
2479 var_n_kwintrude = p0;
2480 if (unlikely(var_n_kwintrude == NULL)) {
2481 PRINT_ERROR("Runtime error: %s", "Cast failed");
2482 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 359);
2483 show_backtrace(1);
2484 }
2485 self->attrs[COLOR_parser_nodes__AIntrudeVisibility___n_kwintrude].val = var_n_kwintrude; /* _n_kwintrude on <self:AIntrudeVisibility> */
2486 if (var_n_kwintrude == NULL) {
2487 PRINT_ERROR("Runtime error: %s", "Receiver is null");
2488 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 360);
2489 show_backtrace(1);
2490 } else {
2491 { /* Inline parser_nodes#ANode#parent= (var_n_kwintrude,self) on <var_n_kwintrude:nullable TKwintrude> */
2492 if (unlikely(var_n_kwintrude == NULL)) {
2493 PRINT_ERROR("Runtime error: %s", "Receiver is null");
2494 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_nodes.nit", 38);
2495 show_backtrace(1);
2496 }
2497 var_n_kwintrude->attrs[COLOR_parser_nodes__ANode___parent].val = self; /* _parent on <var_n_kwintrude:nullable TKwintrude> */
2498 RET_LABEL1:(void)0;
2499 }
2500 }
2501 RET_LABEL:;
2502 }
2503 /* method parser_prod#AIntrudeVisibility#init_aintrudevisibility for (self: Object, nullable TKwintrude) */
2504 void VIRTUAL_parser_prod__AIntrudeVisibility__init_aintrudevisibility(val* self, val* p0) {
2505 parser_prod__AIntrudeVisibility__init_aintrudevisibility(self, p0); /* Direct call parser_prod#AIntrudeVisibility#init_aintrudevisibility on <self:Object(AIntrudeVisibility)>*/
2506 RET_LABEL:;
2507 }
2508 /* method parser_prod#AIntrudeVisibility#replace_child for (self: AIntrudeVisibility, ANode, nullable ANode) */
2509 void parser_prod__AIntrudeVisibility__replace_child(val* self, val* p0, val* p1) {
2510 val* var_old_child /* var old_child: ANode */;
2511 val* var_new_child /* var new_child: nullable ANode */;
2512 val* var /* : TKwintrude */;
2513 short int var1 /* : Bool */;
2514 short int var2 /* : Bool */;
2515 val* var_other /* var other: nullable Object */;
2516 short int var4 /* : Bool */;
2517 short int var6 /* : Bool */;
2518 short int var7 /* : Bool */;
2519 int cltype;
2520 int idtype;
2521 const char* var_class_name;
2522 var_old_child = p0;
2523 var_new_child = p1;
2524 var = self->attrs[COLOR_parser_nodes__AIntrudeVisibility___n_kwintrude].val; /* _n_kwintrude on <self:AIntrudeVisibility> */
2525 if (unlikely(var == NULL)) {
2526 PRINT_ERROR("Runtime error: %s", "Uninitialized attribute _n_kwintrude");
2527 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 365);
2528 show_backtrace(1);
2529 }
2530 {
2531 { /* Inline kernel#Object#== (var,var_old_child) on <var:TKwintrude> */
2532 var_other = var_old_child;
2533 {
2534 { /* Inline kernel#Object#is_same_instance (var,var_other) on <var:TKwintrude> */
2535 var6 = var == var_other;
2536 var4 = var6;
2537 goto RET_LABEL5;
2538 RET_LABEL5:(void)0;
2539 }
2540 }
2541 var2 = var4;
2542 goto RET_LABEL3;
2543 RET_LABEL3:(void)0;
2544 }
2545 var1 = var2;
2546 }
2547 if (var1){
2548 /* <var_new_child:nullable ANode> isa TKwintrude */
2549 cltype = type_parser_nodes__TKwintrude.color;
2550 idtype = type_parser_nodes__TKwintrude.id;
2551 if(var_new_child == NULL) {
2552 var7 = 0;
2553 } else {
2554 if(cltype >= var_new_child->type->table_size) {
2555 var7 = 0;
2556 } else {
2557 var7 = var_new_child->type->type_table[cltype] == idtype;
2558 }
2559 }
2560 if (unlikely(!var7)) {
2561 var_class_name = var_new_child == NULL ? "null" : var_new_child->type->name;
2562 PRINT_ERROR("Runtime error: Cast failed. Expected `%s`, got `%s`", "TKwintrude", var_class_name);
2563 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 366);
2564 show_backtrace(1);
2565 }
2566 {
2567 parser_prod__AIntrudeVisibility__n_kwintrude_61d(self, var_new_child); /* Direct call parser_prod#AIntrudeVisibility#n_kwintrude= on <self:AIntrudeVisibility>*/
2568 }
2569 goto RET_LABEL;
2570 } else {
2571 }
2572 RET_LABEL:;
2573 }
2574 /* method parser_prod#AIntrudeVisibility#replace_child for (self: Object, ANode, nullable ANode) */
2575 void VIRTUAL_parser_prod__AIntrudeVisibility__replace_child(val* self, val* p0, val* p1) {
2576 parser_prod__AIntrudeVisibility__replace_child(self, p0, p1); /* Direct call parser_prod#AIntrudeVisibility#replace_child on <self:Object(AIntrudeVisibility)>*/
2577 RET_LABEL:;
2578 }
2579 /* method parser_prod#AIntrudeVisibility#n_kwintrude= for (self: AIntrudeVisibility, TKwintrude) */
2580 void parser_prod__AIntrudeVisibility__n_kwintrude_61d(val* self, val* p0) {
2581 val* var_node /* var node: TKwintrude */;
2582 var_node = p0;
2583 self->attrs[COLOR_parser_nodes__AIntrudeVisibility___n_kwintrude].val = var_node; /* _n_kwintrude on <self:AIntrudeVisibility> */
2584 {
2585 { /* Inline parser_nodes#ANode#parent= (var_node,self) on <var_node:TKwintrude> */
2586 var_node->attrs[COLOR_parser_nodes__ANode___parent].val = self; /* _parent on <var_node:TKwintrude> */
2587 RET_LABEL1:(void)0;
2588 }
2589 }
2590 RET_LABEL:;
2591 }
2592 /* method parser_prod#AIntrudeVisibility#n_kwintrude= for (self: Object, TKwintrude) */
2593 void VIRTUAL_parser_prod__AIntrudeVisibility__n_kwintrude_61d(val* self, val* p0) {
2594 parser_prod__AIntrudeVisibility__n_kwintrude_61d(self, p0); /* Direct call parser_prod#AIntrudeVisibility#n_kwintrude= on <self:Object(AIntrudeVisibility)>*/
2595 RET_LABEL:;
2596 }
2597 /* method parser_prod#AIntrudeVisibility#visit_all for (self: AIntrudeVisibility, Visitor) */
2598 void parser_prod__AIntrudeVisibility__visit_all(val* self, val* p0) {
2599 val* var_v /* var v: Visitor */;
2600 val* var /* : TKwintrude */;
2601 var_v = p0;
2602 var = self->attrs[COLOR_parser_nodes__AIntrudeVisibility___n_kwintrude].val; /* _n_kwintrude on <self:AIntrudeVisibility> */
2603 if (unlikely(var == NULL)) {
2604 PRINT_ERROR("Runtime error: %s", "Uninitialized attribute _n_kwintrude");
2605 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 380);
2606 show_backtrace(1);
2607 }
2608 {
2609 parser_nodes__Visitor__enter_visit(var_v, var); /* Direct call parser_nodes#Visitor#enter_visit on <var_v:Visitor>*/
2610 }
2611 RET_LABEL:;
2612 }
2613 /* method parser_prod#AIntrudeVisibility#visit_all for (self: Object, Visitor) */
2614 void VIRTUAL_parser_prod__AIntrudeVisibility__visit_all(val* self, val* p0) {
2615 parser_prod__AIntrudeVisibility__visit_all(self, p0); /* Direct call parser_prod#AIntrudeVisibility#visit_all on <self:Object(AIntrudeVisibility)>*/
2616 RET_LABEL:;
2617 }
2618 /* method parser_prod#AStdClassdef#init_astdclassdef for (self: AStdClassdef, nullable ADoc, nullable TKwredef, nullable AVisibility, nullable AClasskind, nullable TClassid, Collection[Object], nullable AAnnotations, nullable AExternCodeBlock, Collection[Object], Collection[Object], nullable TKwend) */
2619 void parser_prod__AStdClassdef__init_astdclassdef(val* self, val* p0, val* p1, val* p2, val* p3, val* p4, val* p5, val* p6, val* p7, val* p8, val* p9, val* p10) {
2620 val* var_n_doc /* var n_doc: nullable ADoc */;
2621 val* var_n_kwredef /* var n_kwredef: nullable TKwredef */;
2622 val* var_n_visibility /* var n_visibility: nullable AVisibility */;
2623 val* var_n_classkind /* var n_classkind: nullable AClasskind */;
2624 val* var_n_id /* var n_id: nullable TClassid */;
2625 val* var_n_formaldefs /* var n_formaldefs: Collection[Object] */;
2626 val* var_n_annotations /* var n_annotations: nullable AAnnotations */;
2627 val* var_n_extern_code_block /* var n_extern_code_block: nullable AExternCodeBlock */;
2628 val* var_n_superclasses /* var n_superclasses: Collection[Object] */;
2629 val* var_n_propdefs /* var n_propdefs: Collection[Object] */;
2630 val* var_n_kwend /* var n_kwend: nullable TKwend */;
2631 val* var /* : null */;
2632 short int var1 /* : Bool */;
2633 short int var2 /* : Bool */;
2634 val* var_other /* var other: nullable Object */;
2635 short int var4 /* : Bool */;
2636 short int var5 /* : Bool */;
2637 short int var6 /* : Bool */;
2638 val* var8 /* : null */;
2639 short int var9 /* : Bool */;
2640 short int var10 /* : Bool */;
2641 short int var12 /* : Bool */;
2642 short int var13 /* : Bool */;
2643 short int var14 /* : Bool */;
2644 val* var18 /* : null */;
2645 short int var19 /* : Bool */;
2646 short int var20 /* : Bool */;
2647 short int var22 /* : Bool */;
2648 short int var23 /* : Bool */;
2649 short int var24 /* : Bool */;
2650 val* var26 /* : ANodes[AFormaldef] */;
2651 val* var28 /* : ANodes[AFormaldef] */;
2652 val* var29 /* : null */;
2653 short int var30 /* : Bool */;
2654 short int var31 /* : Bool */;
2655 short int var33 /* : Bool */;
2656 short int var34 /* : Bool */;
2657 short int var35 /* : Bool */;
2658 val* var37 /* : null */;
2659 short int var38 /* : Bool */;
2660 short int var39 /* : Bool */;
2661 short int var41 /* : Bool */;
2662 short int var42 /* : Bool */;
2663 short int var43 /* : Bool */;
2664 val* var45 /* : ANodes[ASuperclass] */;
2665 val* var47 /* : ANodes[ASuperclass] */;
2666 val* var48 /* : ANodes[APropdef] */;
2667 val* var50 /* : ANodes[APropdef] */;
2668 var_n_doc = p0;
2669 var_n_kwredef = p1;
2670 var_n_visibility = p2;
2671 var_n_classkind = p3;
2672 var_n_id = p4;
2673 var_n_formaldefs = p5;
2674 var_n_annotations = p6;
2675 var_n_extern_code_block = p7;
2676 var_n_superclasses = p8;
2677 var_n_propdefs = p9;
2678 var_n_kwend = p10;
2679 self->attrs[COLOR_parser_nodes__AStdClassdef___n_doc].val = var_n_doc; /* _n_doc on <self:AStdClassdef> */
2680 var = NULL;
2681 if (var_n_doc == NULL) {
2682 var1 = 0; /* is null */
2683 } else {
2684 var1 = 1; /* arg is null and recv is not */
2685 }
2686 if (0) {
2687 { /* Inline kernel#Object#!= (var_n_doc,var) on <var_n_doc:nullable ADoc> */
2688 var_other = var;
2689 {
2690 var5 = ((short int (*)(val*, val*))(var_n_doc->class->vft[COLOR_kernel__Object___61d_61d]))(var_n_doc, var_other) /* == on <var_n_doc:nullable ADoc(ADoc)>*/;
2691 var4 = var5;
2692 }
2693 var6 = !var4;
2694 var2 = var6;
2695 goto RET_LABEL3;
2696 RET_LABEL3:(void)0;
2697 }
2698 var1 = var2;
2699 }
2700 if (var1){
2701 {
2702 { /* Inline parser_nodes#ANode#parent= (var_n_doc,self) on <var_n_doc:nullable ADoc(ADoc)> */
2703 var_n_doc->attrs[COLOR_parser_nodes__ANode___parent].val = self; /* _parent on <var_n_doc:nullable ADoc(ADoc)> */
2704 RET_LABEL7:(void)0;
2705 }
2706 }
2707 } else {
2708 }
2709 self->attrs[COLOR_parser_nodes__AStdClassdef___n_kwredef].val = var_n_kwredef; /* _n_kwredef on <self:AStdClassdef> */
2710 var8 = NULL;
2711 if (var_n_kwredef == NULL) {
2712 var9 = 0; /* is null */
2713 } else {
2714 var9 = 1; /* arg is null and recv is not */
2715 }
2716 if (0) {
2717 { /* Inline kernel#Object#!= (var_n_kwredef,var8) on <var_n_kwredef:nullable TKwredef> */
2718 var_other = var8;
2719 {
2720 var13 = ((short int (*)(val*, val*))(var_n_kwredef->class->vft[COLOR_kernel__Object___61d_61d]))(var_n_kwredef, var_other) /* == on <var_n_kwredef:nullable TKwredef(TKwredef)>*/;
2721 var12 = var13;
2722 }
2723 var14 = !var12;
2724 var10 = var14;
2725 goto RET_LABEL11;
2726 RET_LABEL11:(void)0;
2727 }
2728 var9 = var10;
2729 }
2730 if (var9){
2731 {
2732 { /* Inline parser_nodes#ANode#parent= (var_n_kwredef,self) on <var_n_kwredef:nullable TKwredef(TKwredef)> */
2733 var_n_kwredef->attrs[COLOR_parser_nodes__ANode___parent].val = self; /* _parent on <var_n_kwredef:nullable TKwredef(TKwredef)> */
2734 RET_LABEL15:(void)0;
2735 }
2736 }
2737 } else {
2738 }
2739 if (unlikely(var_n_visibility == NULL)) {
2740 PRINT_ERROR("Runtime error: %s", "Cast failed");
2741 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 402);
2742 show_backtrace(1);
2743 }
2744 self->attrs[COLOR_parser_nodes__AStdClassdef___n_visibility].val = var_n_visibility; /* _n_visibility on <self:AStdClassdef> */
2745 if (var_n_visibility == NULL) {
2746 PRINT_ERROR("Runtime error: %s", "Receiver is null");
2747 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 403);
2748 show_backtrace(1);
2749 } else {
2750 { /* Inline parser_nodes#ANode#parent= (var_n_visibility,self) on <var_n_visibility:nullable AVisibility> */
2751 if (unlikely(var_n_visibility == NULL)) {
2752 PRINT_ERROR("Runtime error: %s", "Receiver is null");
2753 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_nodes.nit", 38);
2754 show_backtrace(1);
2755 }
2756 var_n_visibility->attrs[COLOR_parser_nodes__ANode___parent].val = self; /* _parent on <var_n_visibility:nullable AVisibility> */
2757 RET_LABEL16:(void)0;
2758 }
2759 }
2760 if (unlikely(var_n_classkind == NULL)) {
2761 PRINT_ERROR("Runtime error: %s", "Cast failed");
2762 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 404);
2763 show_backtrace(1);
2764 }
2765 self->attrs[COLOR_parser_nodes__AStdClassdef___n_classkind].val = var_n_classkind; /* _n_classkind on <self:AStdClassdef> */
2766 if (var_n_classkind == NULL) {
2767 PRINT_ERROR("Runtime error: %s", "Receiver is null");
2768 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 405);
2769 show_backtrace(1);
2770 } else {
2771 { /* Inline parser_nodes#ANode#parent= (var_n_classkind,self) on <var_n_classkind:nullable AClasskind> */
2772 if (unlikely(var_n_classkind == NULL)) {
2773 PRINT_ERROR("Runtime error: %s", "Receiver is null");
2774 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_nodes.nit", 38);
2775 show_backtrace(1);
2776 }
2777 var_n_classkind->attrs[COLOR_parser_nodes__ANode___parent].val = self; /* _parent on <var_n_classkind:nullable AClasskind> */
2778 RET_LABEL17:(void)0;
2779 }
2780 }
2781 self->attrs[COLOR_parser_nodes__AStdClassdef___n_id].val = var_n_id; /* _n_id on <self:AStdClassdef> */
2782 var18 = NULL;
2783 if (var_n_id == NULL) {
2784 var19 = 0; /* is null */
2785 } else {
2786 var19 = 1; /* arg is null and recv is not */
2787 }
2788 if (0) {
2789 { /* Inline kernel#Object#!= (var_n_id,var18) on <var_n_id:nullable TClassid> */
2790 var_other = var18;
2791 {
2792 var23 = ((short int (*)(val*, val*))(var_n_id->class->vft[COLOR_kernel__Object___61d_61d]))(var_n_id, var_other) /* == on <var_n_id:nullable TClassid(TClassid)>*/;
2793 var22 = var23;
2794 }
2795 var24 = !var22;
2796 var20 = var24;
2797 goto RET_LABEL21;
2798 RET_LABEL21:(void)0;
2799 }
2800 var19 = var20;
2801 }
2802 if (var19){
2803 {
2804 { /* Inline parser_nodes#ANode#parent= (var_n_id,self) on <var_n_id:nullable TClassid(TClassid)> */
2805 var_n_id->attrs[COLOR_parser_nodes__ANode___parent].val = self; /* _parent on <var_n_id:nullable TClassid(TClassid)> */
2806 RET_LABEL25:(void)0;
2807 }
2808 }
2809 } else {
2810 }
2811 {
2812 { /* Inline parser_nodes#AStdClassdef#n_formaldefs (self) on <self:AStdClassdef> */
2813 var28 = self->attrs[COLOR_parser_nodes__AStdClassdef___n_formaldefs].val; /* _n_formaldefs on <self:AStdClassdef> */
2814 if (unlikely(var28 == NULL)) {
2815 PRINT_ERROR("Runtime error: %s", "Uninitialized attribute _n_formaldefs");
2816 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_nodes.nit", 824);
2817 show_backtrace(1);
2818 }
2819 var26 = var28;
2820 RET_LABEL27:(void)0;
2821 }
2822 }
2823 {
2824 parser_nodes__ANodes__unsafe_add_all(var26, var_n_formaldefs); /* Direct call parser_nodes#ANodes#unsafe_add_all on <var26:ANodes[AFormaldef]>*/
2825 }
2826 self->attrs[COLOR_parser_nodes__Prod___n_annotations].val = var_n_annotations; /* _n_annotations on <self:AStdClassdef> */
2827 var29 = NULL;
2828 if (var_n_annotations == NULL) {
2829 var30 = 0; /* is null */
2830 } else {
2831 var30 = 1; /* arg is null and recv is not */
2832 }
2833 if (0) {
2834 { /* Inline kernel#Object#!= (var_n_annotations,var29) on <var_n_annotations:nullable AAnnotations> */
2835 var_other = var29;
2836 {
2837 var34 = ((short int (*)(val*, val*))(var_n_annotations->class->vft[COLOR_kernel__Object___61d_61d]))(var_n_annotations, var_other) /* == on <var_n_annotations:nullable AAnnotations(AAnnotations)>*/;
2838 var33 = var34;
2839 }
2840 var35 = !var33;
2841 var31 = var35;
2842 goto RET_LABEL32;
2843 RET_LABEL32:(void)0;
2844 }
2845 var30 = var31;
2846 }
2847 if (var30){
2848 {
2849 { /* Inline parser_nodes#ANode#parent= (var_n_annotations,self) on <var_n_annotations:nullable AAnnotations(AAnnotations)> */
2850 var_n_annotations->attrs[COLOR_parser_nodes__ANode___parent].val = self; /* _parent on <var_n_annotations:nullable AAnnotations(AAnnotations)> */
2851 RET_LABEL36:(void)0;
2852 }
2853 }
2854 } else {
2855 }
2856 self->attrs[COLOR_parser_nodes__AStdClassdef___n_extern_code_block].val = var_n_extern_code_block; /* _n_extern_code_block on <self:AStdClassdef> */
2857 var37 = NULL;
2858 if (var_n_extern_code_block == NULL) {
2859 var38 = 0; /* is null */
2860 } else {
2861 var38 = 1; /* arg is null and recv is not */
2862 }
2863 if (0) {
2864 { /* Inline kernel#Object#!= (var_n_extern_code_block,var37) on <var_n_extern_code_block:nullable AExternCodeBlock> */
2865 var_other = var37;
2866 {
2867 var42 = ((short int (*)(val*, val*))(var_n_extern_code_block->class->vft[COLOR_kernel__Object___61d_61d]))(var_n_extern_code_block, var_other) /* == on <var_n_extern_code_block:nullable AExternCodeBlock(AExternCodeBlock)>*/;
2868 var41 = var42;
2869 }
2870 var43 = !var41;
2871 var39 = var43;
2872 goto RET_LABEL40;
2873 RET_LABEL40:(void)0;
2874 }
2875 var38 = var39;
2876 }
2877 if (var38){
2878 {
2879 { /* Inline parser_nodes#ANode#parent= (var_n_extern_code_block,self) on <var_n_extern_code_block:nullable AExternCodeBlock(AExternCodeBlock)> */
2880 var_n_extern_code_block->attrs[COLOR_parser_nodes__ANode___parent].val = self; /* _parent on <var_n_extern_code_block:nullable AExternCodeBlock(AExternCodeBlock)> */
2881 RET_LABEL44:(void)0;
2882 }
2883 }
2884 } else {
2885 }
2886 {
2887 { /* Inline parser_nodes#AStdClassdef#n_superclasses (self) on <self:AStdClassdef> */
2888 var47 = self->attrs[COLOR_parser_nodes__AStdClassdef___n_superclasses].val; /* _n_superclasses on <self:AStdClassdef> */
2889 if (unlikely(var47 == NULL)) {
2890 PRINT_ERROR("Runtime error: %s", "Uninitialized attribute _n_superclasses");
2891 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_nodes.nit", 828);
2892 show_backtrace(1);
2893 }
2894 var45 = var47;
2895 RET_LABEL46:(void)0;
2896 }
2897 }
2898 {
2899 parser_nodes__ANodes__unsafe_add_all(var45, var_n_superclasses); /* Direct call parser_nodes#ANodes#unsafe_add_all on <var45:ANodes[ASuperclass]>*/
2900 }
2901 {
2902 { /* Inline parser_nodes#AClassdef#n_propdefs (self) on <self:AStdClassdef> */
2903 var50 = self->attrs[COLOR_parser_nodes__AClassdef___n_propdefs].val; /* _n_propdefs on <self:AStdClassdef> */
2904 if (unlikely(var50 == NULL)) {
2905 PRINT_ERROR("Runtime error: %s", "Uninitialized attribute _n_propdefs");
2906 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_nodes.nit", 802);
2907 show_backtrace(1);
2908 }
2909 var48 = var50;
2910 RET_LABEL49:(void)0;
2911 }
2912 }
2913 {
2914 parser_nodes__ANodes__unsafe_add_all(var48, var_n_propdefs); /* Direct call parser_nodes#ANodes#unsafe_add_all on <var48:ANodes[APropdef]>*/
2915 }
2916 if (unlikely(var_n_kwend == NULL)) {
2917 PRINT_ERROR("Runtime error: %s", "Cast failed");
2918 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 415);
2919 show_backtrace(1);
2920 }
2921 self->attrs[COLOR_parser_nodes__AStdClassdef___n_kwend].val = var_n_kwend; /* _n_kwend on <self:AStdClassdef> */
2922 if (var_n_kwend == NULL) {
2923 PRINT_ERROR("Runtime error: %s", "Receiver is null");
2924 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 416);
2925 show_backtrace(1);
2926 } else {
2927 { /* Inline parser_nodes#ANode#parent= (var_n_kwend,self) on <var_n_kwend:nullable TKwend> */
2928 if (unlikely(var_n_kwend == NULL)) {
2929 PRINT_ERROR("Runtime error: %s", "Receiver is null");
2930 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_nodes.nit", 38);
2931 show_backtrace(1);
2932 }
2933 var_n_kwend->attrs[COLOR_parser_nodes__ANode___parent].val = self; /* _parent on <var_n_kwend:nullable TKwend> */
2934 RET_LABEL51:(void)0;
2935 }
2936 }
2937 RET_LABEL:;
2938 }
2939 /* method parser_prod#AStdClassdef#init_astdclassdef for (self: Object, nullable ADoc, nullable TKwredef, nullable AVisibility, nullable AClasskind, nullable TClassid, Collection[Object], nullable AAnnotations, nullable AExternCodeBlock, Collection[Object], Collection[Object], nullable TKwend) */
2940 void VIRTUAL_parser_prod__AStdClassdef__init_astdclassdef(val* self, val* p0, val* p1, val* p2, val* p3, val* p4, val* p5, val* p6, val* p7, val* p8, val* p9, val* p10) {
2941 parser_prod__AStdClassdef__init_astdclassdef(self, p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10); /* Direct call parser_prod#AStdClassdef#init_astdclassdef on <self:Object(AStdClassdef)>*/
2942 RET_LABEL:;
2943 }
2944 /* method parser_prod#AStdClassdef#replace_child for (self: AStdClassdef, ANode, nullable ANode) */
2945 void parser_prod__AStdClassdef__replace_child(val* self, val* p0, val* p1) {
2946 val* var_old_child /* var old_child: ANode */;
2947 val* var_new_child /* var new_child: nullable ANode */;
2948 val* var /* : nullable ADoc */;
2949 short int var1 /* : Bool */;
2950 short int var2 /* : Bool */;
2951 val* var_other /* var other: nullable Object */;
2952 short int var4 /* : Bool */;
2953 short int var6 /* : Bool */;
2954 short int var7 /* : Bool */;
2955 int cltype;
2956 int idtype;
2957 const char* var_class_name;
2958 val* var8 /* : nullable TKwredef */;
2959 short int var9 /* : Bool */;
2960 short int var10 /* : Bool */;
2961 short int var12 /* : Bool */;
2962 short int var14 /* : Bool */;
2963 short int var15 /* : Bool */;
2964 int cltype16;
2965 int idtype17;
2966 const char* var_class_name18;
2967 val* var19 /* : AVisibility */;
2968 short int var20 /* : Bool */;
2969 short int var21 /* : Bool */;
2970 short int var23 /* : Bool */;
2971 short int var25 /* : Bool */;
2972 short int var26 /* : Bool */;
2973 int cltype27;
2974 int idtype28;
2975 const char* var_class_name29;
2976 val* var30 /* : AClasskind */;
2977 short int var31 /* : Bool */;
2978 short int var32 /* : Bool */;
2979 short int var34 /* : Bool */;
2980 short int var36 /* : Bool */;
2981 short int var37 /* : Bool */;
2982 int cltype38;
2983 int idtype39;
2984 const char* var_class_name40;
2985 val* var41 /* : nullable TClassid */;
2986 short int var42 /* : Bool */;
2987 short int var43 /* : Bool */;
2988 short int var45 /* : Bool */;
2989 short int var47 /* : Bool */;
2990 short int var48 /* : Bool */;
2991 int cltype49;
2992 int idtype50;
2993 const char* var_class_name51;
2994 val* var52 /* : ANodes[AFormaldef] */;
2995 val* var54 /* : ANodes[AFormaldef] */;
2996 short int var55 /* : Bool */;
2997 val* var56 /* : nullable AAnnotations */;
2998 short int var57 /* : Bool */;
2999 short int var58 /* : Bool */;
3000 short int var60 /* : Bool */;
3001 short int var62 /* : Bool */;
3002 short int var63 /* : Bool */;
3003 int cltype64;
3004 int idtype65;
3005 const char* var_class_name66;
3006 val* var67 /* : nullable AExternCodeBlock */;
3007 short int var68 /* : Bool */;
3008 short int var69 /* : Bool */;
3009 short int var71 /* : Bool */;
3010 short int var73 /* : Bool */;
3011 short int var74 /* : Bool */;
3012 int cltype75;
3013 int idtype76;
3014 const char* var_class_name77;
3015 val* var78 /* : ANodes[ASuperclass] */;
3016 val* var80 /* : ANodes[ASuperclass] */;
3017 short int var81 /* : Bool */;
3018 val* var82 /* : ANodes[APropdef] */;
3019 val* var84 /* : ANodes[APropdef] */;
3020 short int var85 /* : Bool */;
3021 val* var86 /* : TKwend */;
3022 short int var87 /* : Bool */;
3023 short int var88 /* : Bool */;
3024 short int var90 /* : Bool */;
3025 short int var92 /* : Bool */;
3026 short int var93 /* : Bool */;
3027 int cltype94;
3028 int idtype95;
3029 const char* var_class_name96;
3030 var_old_child = p0;
3031 var_new_child = p1;
3032 var = self->attrs[COLOR_parser_nodes__AStdClassdef___n_doc].val; /* _n_doc on <self:AStdClassdef> */
3033 if (var == NULL) {
3034 var1 = 0; /* <var_old_child:ANode> cannot be null */
3035 } else {
3036 { /* Inline kernel#Object#== (var,var_old_child) on <var:nullable ADoc> */
3037 var_other = var_old_child;
3038 {
3039 { /* Inline kernel#Object#is_same_instance (var,var_other) on <var:nullable ADoc(ADoc)> */
3040 var6 = var == var_other;
3041 var4 = var6;
3042 goto RET_LABEL5;
3043 RET_LABEL5:(void)0;
3044 }
3045 }
3046 var2 = var4;
3047 goto RET_LABEL3;
3048 RET_LABEL3:(void)0;
3049 }
3050 var1 = var2;
3051 }
3052 if (var1){
3053 /* <var_new_child:nullable ANode> isa nullable ADoc */
3054 cltype = type_nullable_parser_nodes__ADoc.color;
3055 idtype = type_nullable_parser_nodes__ADoc.id;
3056 if(var_new_child == NULL) {
3057 var7 = 1;
3058 } else {
3059 if(cltype >= var_new_child->type->table_size) {
3060 var7 = 0;
3061 } else {
3062 var7 = var_new_child->type->type_table[cltype] == idtype;
3063 }
3064 }
3065 if (unlikely(!var7)) {
3066 var_class_name = var_new_child == NULL ? "null" : var_new_child->type->name;
3067 PRINT_ERROR("Runtime error: Cast failed. Expected `%s`, got `%s`", "nullable ADoc", var_class_name);
3068 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 422);
3069 show_backtrace(1);
3070 }
3071 {
3072 parser_prod__AStdClassdef__n_doc_61d(self, var_new_child); /* Direct call parser_prod#AStdClassdef#n_doc= on <self:AStdClassdef>*/
3073 }
3074 goto RET_LABEL;
3075 } else {
3076 }
3077 var8 = self->attrs[COLOR_parser_nodes__AStdClassdef___n_kwredef].val; /* _n_kwredef on <self:AStdClassdef> */
3078 if (var8 == NULL) {
3079 var9 = 0; /* <var_old_child:ANode> cannot be null */
3080 } else {
3081 { /* Inline kernel#Object#== (var8,var_old_child) on <var8:nullable TKwredef> */
3082 var_other = var_old_child;
3083 {
3084 { /* Inline kernel#Object#is_same_instance (var8,var_other) on <var8:nullable TKwredef(TKwredef)> */
3085 var14 = var8 == var_other;
3086 var12 = var14;
3087 goto RET_LABEL13;
3088 RET_LABEL13:(void)0;
3089 }
3090 }
3091 var10 = var12;
3092 goto RET_LABEL11;
3093 RET_LABEL11:(void)0;
3094 }
3095 var9 = var10;
3096 }
3097 if (var9){
3098 /* <var_new_child:nullable ANode> isa nullable TKwredef */
3099 cltype16 = type_nullable_parser_nodes__TKwredef.color;
3100 idtype17 = type_nullable_parser_nodes__TKwredef.id;
3101 if(var_new_child == NULL) {
3102 var15 = 1;
3103 } else {
3104 if(cltype16 >= var_new_child->type->table_size) {
3105 var15 = 0;
3106 } else {
3107 var15 = var_new_child->type->type_table[cltype16] == idtype17;
3108 }
3109 }
3110 if (unlikely(!var15)) {
3111 var_class_name18 = var_new_child == NULL ? "null" : var_new_child->type->name;
3112 PRINT_ERROR("Runtime error: Cast failed. Expected `%s`, got `%s`", "nullable TKwredef", var_class_name18);
3113 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 426);
3114 show_backtrace(1);
3115 }
3116 {
3117 parser_prod__AStdClassdef__n_kwredef_61d(self, var_new_child); /* Direct call parser_prod#AStdClassdef#n_kwredef= on <self:AStdClassdef>*/
3118 }
3119 goto RET_LABEL;
3120 } else {
3121 }
3122 var19 = self->attrs[COLOR_parser_nodes__AStdClassdef___n_visibility].val; /* _n_visibility on <self:AStdClassdef> */
3123 if (unlikely(var19 == NULL)) {
3124 PRINT_ERROR("Runtime error: %s", "Uninitialized attribute _n_visibility");
3125 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 429);
3126 show_backtrace(1);
3127 }
3128 {
3129 { /* Inline kernel#Object#== (var19,var_old_child) on <var19:AVisibility> */
3130 var_other = var_old_child;
3131 {
3132 { /* Inline kernel#Object#is_same_instance (var19,var_other) on <var19:AVisibility> */
3133 var25 = var19 == var_other;
3134 var23 = var25;
3135 goto RET_LABEL24;
3136 RET_LABEL24:(void)0;
3137 }
3138 }
3139 var21 = var23;
3140 goto RET_LABEL22;
3141 RET_LABEL22:(void)0;
3142 }
3143 var20 = var21;
3144 }
3145 if (var20){
3146 /* <var_new_child:nullable ANode> isa AVisibility */
3147 cltype27 = type_parser_nodes__AVisibility.color;
3148 idtype28 = type_parser_nodes__AVisibility.id;
3149 if(var_new_child == NULL) {
3150 var26 = 0;
3151 } else {
3152 if(cltype27 >= var_new_child->type->table_size) {
3153 var26 = 0;
3154 } else {
3155 var26 = var_new_child->type->type_table[cltype27] == idtype28;
3156 }
3157 }
3158 if (unlikely(!var26)) {
3159 var_class_name29 = var_new_child == NULL ? "null" : var_new_child->type->name;
3160 PRINT_ERROR("Runtime error: Cast failed. Expected `%s`, got `%s`", "AVisibility", var_class_name29);
3161 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 430);
3162 show_backtrace(1);
3163 }
3164 {
3165 parser_prod__AStdClassdef__n_visibility_61d(self, var_new_child); /* Direct call parser_prod#AStdClassdef#n_visibility= on <self:AStdClassdef>*/
3166 }
3167 goto RET_LABEL;
3168 } else {
3169 }
3170 var30 = self->attrs[COLOR_parser_nodes__AStdClassdef___n_classkind].val; /* _n_classkind on <self:AStdClassdef> */
3171 if (unlikely(var30 == NULL)) {
3172 PRINT_ERROR("Runtime error: %s", "Uninitialized attribute _n_classkind");
3173 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 433);
3174 show_backtrace(1);
3175 }
3176 {
3177 { /* Inline kernel#Object#== (var30,var_old_child) on <var30:AClasskind> */
3178 var_other = var_old_child;
3179 {
3180 { /* Inline kernel#Object#is_same_instance (var30,var_other) on <var30:AClasskind> */
3181 var36 = var30 == var_other;
3182 var34 = var36;
3183 goto RET_LABEL35;
3184 RET_LABEL35:(void)0;
3185 }
3186 }
3187 var32 = var34;
3188 goto RET_LABEL33;
3189 RET_LABEL33:(void)0;
3190 }
3191 var31 = var32;
3192 }
3193 if (var31){
3194 /* <var_new_child:nullable ANode> isa AClasskind */
3195 cltype38 = type_parser_nodes__AClasskind.color;
3196 idtype39 = type_parser_nodes__AClasskind.id;
3197 if(var_new_child == NULL) {
3198 var37 = 0;
3199 } else {
3200 if(cltype38 >= var_new_child->type->table_size) {
3201 var37 = 0;
3202 } else {
3203 var37 = var_new_child->type->type_table[cltype38] == idtype39;
3204 }
3205 }
3206 if (unlikely(!var37)) {
3207 var_class_name40 = var_new_child == NULL ? "null" : var_new_child->type->name;
3208 PRINT_ERROR("Runtime error: Cast failed. Expected `%s`, got `%s`", "AClasskind", var_class_name40);
3209 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 434);
3210 show_backtrace(1);
3211 }
3212 {
3213 parser_prod__AStdClassdef__n_classkind_61d(self, var_new_child); /* Direct call parser_prod#AStdClassdef#n_classkind= on <self:AStdClassdef>*/
3214 }
3215 goto RET_LABEL;
3216 } else {
3217 }
3218 var41 = self->attrs[COLOR_parser_nodes__AStdClassdef___n_id].val; /* _n_id on <self:AStdClassdef> */
3219 if (var41 == NULL) {
3220 var42 = 0; /* <var_old_child:ANode> cannot be null */
3221 } else {
3222 { /* Inline kernel#Object#== (var41,var_old_child) on <var41:nullable TClassid> */
3223 var_other = var_old_child;
3224 {
3225 { /* Inline kernel#Object#is_same_instance (var41,var_other) on <var41:nullable TClassid(TClassid)> */
3226 var47 = var41 == var_other;
3227 var45 = var47;
3228 goto RET_LABEL46;
3229 RET_LABEL46:(void)0;
3230 }
3231 }
3232 var43 = var45;
3233 goto RET_LABEL44;
3234 RET_LABEL44:(void)0;
3235 }
3236 var42 = var43;
3237 }
3238 if (var42){
3239 /* <var_new_child:nullable ANode> isa nullable TClassid */
3240 cltype49 = type_nullable_parser_nodes__TClassid.color;
3241 idtype50 = type_nullable_parser_nodes__TClassid.id;
3242 if(var_new_child == NULL) {
3243 var48 = 1;
3244 } else {
3245 if(cltype49 >= var_new_child->type->table_size) {
3246 var48 = 0;
3247 } else {
3248 var48 = var_new_child->type->type_table[cltype49] == idtype50;
3249 }
3250 }
3251 if (unlikely(!var48)) {
3252 var_class_name51 = var_new_child == NULL ? "null" : var_new_child->type->name;
3253 PRINT_ERROR("Runtime error: Cast failed. Expected `%s`, got `%s`", "nullable TClassid", var_class_name51);
3254 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 438);
3255 show_backtrace(1);
3256 }
3257 {
3258 parser_prod__AStdClassdef__n_id_61d(self, var_new_child); /* Direct call parser_prod#AStdClassdef#n_id= on <self:AStdClassdef>*/
3259 }
3260 goto RET_LABEL;
3261 } else {
3262 }
3263 {
3264 { /* Inline parser_nodes#AStdClassdef#n_formaldefs (self) on <self:AStdClassdef> */
3265 var54 = self->attrs[COLOR_parser_nodes__AStdClassdef___n_formaldefs].val; /* _n_formaldefs on <self:AStdClassdef> */
3266 if (unlikely(var54 == NULL)) {
3267 PRINT_ERROR("Runtime error: %s", "Uninitialized attribute _n_formaldefs");
3268 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_nodes.nit", 824);
3269 show_backtrace(1);
3270 }
3271 var52 = var54;
3272 RET_LABEL53:(void)0;
3273 }
3274 }
3275 {
3276 var55 = parser_nodes__ANodes__replace_child(var52, var_old_child, var_new_child);
3277 }
3278 if (var55){
3279 goto RET_LABEL;
3280 } else {
3281 }
3282 var56 = self->attrs[COLOR_parser_nodes__Prod___n_annotations].val; /* _n_annotations on <self:AStdClassdef> */
3283 if (var56 == NULL) {
3284 var57 = 0; /* <var_old_child:ANode> cannot be null */
3285 } else {
3286 { /* Inline kernel#Object#== (var56,var_old_child) on <var56:nullable AAnnotations> */
3287 var_other = var_old_child;
3288 {
3289 { /* Inline kernel#Object#is_same_instance (var56,var_other) on <var56:nullable AAnnotations(AAnnotations)> */
3290 var62 = var56 == var_other;
3291 var60 = var62;
3292 goto RET_LABEL61;
3293 RET_LABEL61:(void)0;
3294 }
3295 }
3296 var58 = var60;
3297 goto RET_LABEL59;
3298 RET_LABEL59:(void)0;
3299 }
3300 var57 = var58;
3301 }
3302 if (var57){
3303 /* <var_new_child:nullable ANode> isa nullable AAnnotations */
3304 cltype64 = type_nullable_parser_nodes__AAnnotations.color;
3305 idtype65 = type_nullable_parser_nodes__AAnnotations.id;
3306 if(var_new_child == NULL) {
3307 var63 = 1;
3308 } else {
3309 if(cltype64 >= var_new_child->type->table_size) {
3310 var63 = 0;
3311 } else {
3312 var63 = var_new_child->type->type_table[cltype64] == idtype65;
3313 }
3314 }
3315 if (unlikely(!var63)) {
3316 var_class_name66 = var_new_child == NULL ? "null" : var_new_child->type->name;
3317 PRINT_ERROR("Runtime error: Cast failed. Expected `%s`, got `%s`", "nullable AAnnotations", var_class_name66);
3318 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 443);
3319 show_backtrace(1);
3320 }
3321 {
3322 parser_prod__AStdClassdef__n_annotations_61d(self, var_new_child); /* Direct call parser_prod#AStdClassdef#n_annotations= on <self:AStdClassdef>*/
3323 }
3324 goto RET_LABEL;
3325 } else {
3326 }
3327 var67 = self->attrs[COLOR_parser_nodes__AStdClassdef___n_extern_code_block].val; /* _n_extern_code_block on <self:AStdClassdef> */
3328 if (var67 == NULL) {
3329 var68 = 0; /* <var_old_child:ANode> cannot be null */
3330 } else {
3331 { /* Inline kernel#Object#== (var67,var_old_child) on <var67:nullable AExternCodeBlock> */
3332 var_other = var_old_child;
3333 {
3334 { /* Inline kernel#Object#is_same_instance (var67,var_other) on <var67:nullable AExternCodeBlock(AExternCodeBlock)> */
3335 var73 = var67 == var_other;
3336 var71 = var73;
3337 goto RET_LABEL72;
3338 RET_LABEL72:(void)0;
3339 }
3340 }
3341 var69 = var71;
3342 goto RET_LABEL70;
3343 RET_LABEL70:(void)0;
3344 }
3345 var68 = var69;
3346 }
3347 if (var68){
3348 /* <var_new_child:nullable ANode> isa nullable AExternCodeBlock */
3349 cltype75 = type_nullable_parser_nodes__AExternCodeBlock.color;
3350 idtype76 = type_nullable_parser_nodes__AExternCodeBlock.id;
3351 if(var_new_child == NULL) {
3352 var74 = 1;
3353 } else {
3354 if(cltype75 >= var_new_child->type->table_size) {
3355 var74 = 0;
3356 } else {
3357 var74 = var_new_child->type->type_table[cltype75] == idtype76;
3358 }
3359 }
3360 if (unlikely(!var74)) {
3361 var_class_name77 = var_new_child == NULL ? "null" : var_new_child->type->name;
3362 PRINT_ERROR("Runtime error: Cast failed. Expected `%s`, got `%s`", "nullable AExternCodeBlock", var_class_name77);
3363 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 447);
3364 show_backtrace(1);
3365 }
3366 {
3367 parser_prod__AStdClassdef__n_extern_code_block_61d(self, var_new_child); /* Direct call parser_prod#AStdClassdef#n_extern_code_block= on <self:AStdClassdef>*/
3368 }
3369 goto RET_LABEL;
3370 } else {
3371 }
3372 {
3373 { /* Inline parser_nodes#AStdClassdef#n_superclasses (self) on <self:AStdClassdef> */
3374 var80 = self->attrs[COLOR_parser_nodes__AStdClassdef___n_superclasses].val; /* _n_superclasses on <self:AStdClassdef> */
3375 if (unlikely(var80 == NULL)) {
3376 PRINT_ERROR("Runtime error: %s", "Uninitialized attribute _n_superclasses");
3377 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_nodes.nit", 828);
3378 show_backtrace(1);
3379 }
3380 var78 = var80;
3381 RET_LABEL79:(void)0;
3382 }
3383 }
3384 {
3385 var81 = parser_nodes__ANodes__replace_child(var78, var_old_child, var_new_child);
3386 }
3387 if (var81){
3388 goto RET_LABEL;
3389 } else {
3390 }
3391 {
3392 { /* Inline parser_nodes#AClassdef#n_propdefs (self) on <self:AStdClassdef> */
3393 var84 = self->attrs[COLOR_parser_nodes__AClassdef___n_propdefs].val; /* _n_propdefs on <self:AStdClassdef> */
3394 if (unlikely(var84 == NULL)) {
3395 PRINT_ERROR("Runtime error: %s", "Uninitialized attribute _n_propdefs");
3396 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_nodes.nit", 802);
3397 show_backtrace(1);
3398 }
3399 var82 = var84;
3400 RET_LABEL83:(void)0;
3401 }
3402 }
3403 {
3404 var85 = parser_nodes__ANodes__replace_child(var82, var_old_child, var_new_child);
3405 }
3406 if (var85){
3407 goto RET_LABEL;
3408 } else {
3409 }
3410 var86 = self->attrs[COLOR_parser_nodes__AStdClassdef___n_kwend].val; /* _n_kwend on <self:AStdClassdef> */
3411 if (unlikely(var86 == NULL)) {
3412 PRINT_ERROR("Runtime error: %s", "Uninitialized attribute _n_kwend");
3413 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 452);
3414 show_backtrace(1);
3415 }
3416 {
3417 { /* Inline kernel#Object#== (var86,var_old_child) on <var86:TKwend> */
3418 var_other = var_old_child;
3419 {
3420 { /* Inline kernel#Object#is_same_instance (var86,var_other) on <var86:TKwend> */
3421 var92 = var86 == var_other;
3422 var90 = var92;
3423 goto RET_LABEL91;
3424 RET_LABEL91:(void)0;
3425 }
3426 }
3427 var88 = var90;
3428 goto RET_LABEL89;
3429 RET_LABEL89:(void)0;
3430 }
3431 var87 = var88;
3432 }
3433 if (var87){
3434 /* <var_new_child:nullable ANode> isa TKwend */
3435 cltype94 = type_parser_nodes__TKwend.color;
3436 idtype95 = type_parser_nodes__TKwend.id;
3437 if(var_new_child == NULL) {
3438 var93 = 0;
3439 } else {
3440 if(cltype94 >= var_new_child->type->table_size) {
3441 var93 = 0;
3442 } else {
3443 var93 = var_new_child->type->type_table[cltype94] == idtype95;
3444 }
3445 }
3446 if (unlikely(!var93)) {
3447 var_class_name96 = var_new_child == NULL ? "null" : var_new_child->type->name;
3448 PRINT_ERROR("Runtime error: Cast failed. Expected `%s`, got `%s`", "TKwend", var_class_name96);
3449 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 453);
3450 show_backtrace(1);
3451 }
3452 {
3453 parser_prod__AStdClassdef__n_kwend_61d(self, var_new_child); /* Direct call parser_prod#AStdClassdef#n_kwend= on <self:AStdClassdef>*/
3454 }
3455 goto RET_LABEL;
3456 } else {
3457 }
3458 RET_LABEL:;
3459 }
3460 /* method parser_prod#AStdClassdef#replace_child for (self: Object, ANode, nullable ANode) */
3461 void VIRTUAL_parser_prod__AStdClassdef__replace_child(val* self, val* p0, val* p1) {
3462 parser_prod__AStdClassdef__replace_child(self, p0, p1); /* Direct call parser_prod#AStdClassdef#replace_child on <self:Object(AStdClassdef)>*/
3463 RET_LABEL:;
3464 }
3465 /* method parser_prod#AStdClassdef#n_doc= for (self: AStdClassdef, nullable ADoc) */
3466 void parser_prod__AStdClassdef__n_doc_61d(val* self, val* p0) {
3467 val* var_node /* var node: nullable ADoc */;
3468 val* var /* : null */;
3469 short int var1 /* : Bool */;
3470 short int var2 /* : Bool */;
3471 val* var_other /* var other: nullable Object */;
3472 short int var4 /* : Bool */;
3473 short int var5 /* : Bool */;
3474 short int var6 /* : Bool */;
3475 var_node = p0;
3476 self->attrs[COLOR_parser_nodes__AStdClassdef___n_doc].val = var_node; /* _n_doc on <self:AStdClassdef> */
3477 var = NULL;
3478 if (var_node == NULL) {
3479 var1 = 0; /* is null */
3480 } else {
3481 var1 = 1; /* arg is null and recv is not */
3482 }
3483 if (0) {
3484 { /* Inline kernel#Object#!= (var_node,var) on <var_node:nullable ADoc> */
3485 var_other = var;
3486 {
3487 var5 = ((short int (*)(val*, val*))(var_node->class->vft[COLOR_kernel__Object___61d_61d]))(var_node, var_other) /* == on <var_node:nullable ADoc(ADoc)>*/;
3488 var4 = var5;
3489 }
3490 var6 = !var4;
3491 var2 = var6;
3492 goto RET_LABEL3;
3493 RET_LABEL3:(void)0;
3494 }
3495 var1 = var2;
3496 }
3497 if (var1){
3498 {
3499 { /* Inline parser_nodes#ANode#parent= (var_node,self) on <var_node:nullable ADoc(ADoc)> */
3500 var_node->attrs[COLOR_parser_nodes__ANode___parent].val = self; /* _parent on <var_node:nullable ADoc(ADoc)> */
3501 RET_LABEL7:(void)0;
3502 }
3503 }
3504 } else {
3505 }
3506 RET_LABEL:;
3507 }
3508 /* method parser_prod#AStdClassdef#n_doc= for (self: Object, nullable ADoc) */
3509 void VIRTUAL_parser_prod__AStdClassdef__n_doc_61d(val* self, val* p0) {
3510 parser_prod__AStdClassdef__n_doc_61d(self, p0); /* Direct call parser_prod#AStdClassdef#n_doc= on <self:Object(AStdClassdef)>*/
3511 RET_LABEL:;
3512 }
3513 /* method parser_prod#AStdClassdef#n_kwredef= for (self: AStdClassdef, nullable TKwredef) */
3514 void parser_prod__AStdClassdef__n_kwredef_61d(val* self, val* p0) {
3515 val* var_node /* var node: nullable TKwredef */;
3516 val* var /* : null */;
3517 short int var1 /* : Bool */;
3518 short int var2 /* : Bool */;
3519 val* var_other /* var other: nullable Object */;
3520 short int var4 /* : Bool */;
3521 short int var5 /* : Bool */;
3522 short int var6 /* : Bool */;
3523 var_node = p0;
3524 self->attrs[COLOR_parser_nodes__AStdClassdef___n_kwredef].val = var_node; /* _n_kwredef on <self:AStdClassdef> */
3525 var = NULL;
3526 if (var_node == NULL) {
3527 var1 = 0; /* is null */
3528 } else {
3529 var1 = 1; /* arg is null and recv is not */
3530 }
3531 if (0) {
3532 { /* Inline kernel#Object#!= (var_node,var) on <var_node:nullable TKwredef> */
3533 var_other = var;
3534 {
3535 var5 = ((short int (*)(val*, val*))(var_node->class->vft[COLOR_kernel__Object___61d_61d]))(var_node, var_other) /* == on <var_node:nullable TKwredef(TKwredef)>*/;
3536 var4 = var5;
3537 }
3538 var6 = !var4;
3539 var2 = var6;
3540 goto RET_LABEL3;
3541 RET_LABEL3:(void)0;
3542 }
3543 var1 = var2;
3544 }
3545 if (var1){
3546 {
3547 { /* Inline parser_nodes#ANode#parent= (var_node,self) on <var_node:nullable TKwredef(TKwredef)> */
3548 var_node->attrs[COLOR_parser_nodes__ANode___parent].val = self; /* _parent on <var_node:nullable TKwredef(TKwredef)> */
3549 RET_LABEL7:(void)0;
3550 }
3551 }
3552 } else {
3553 }
3554 RET_LABEL:;
3555 }
3556 /* method parser_prod#AStdClassdef#n_kwredef= for (self: Object, nullable TKwredef) */
3557 void VIRTUAL_parser_prod__AStdClassdef__n_kwredef_61d(val* self, val* p0) {
3558 parser_prod__AStdClassdef__n_kwredef_61d(self, p0); /* Direct call parser_prod#AStdClassdef#n_kwredef= on <self:Object(AStdClassdef)>*/
3559 RET_LABEL:;
3560 }
3561 /* method parser_prod#AStdClassdef#n_visibility= for (self: AStdClassdef, AVisibility) */
3562 void parser_prod__AStdClassdef__n_visibility_61d(val* self, val* p0) {
3563 val* var_node /* var node: AVisibility */;
3564 var_node = p0;
3565 self->attrs[COLOR_parser_nodes__AStdClassdef___n_visibility].val = var_node; /* _n_visibility on <self:AStdClassdef> */
3566 {
3567 { /* Inline parser_nodes#ANode#parent= (var_node,self) on <var_node:AVisibility> */
3568 var_node->attrs[COLOR_parser_nodes__ANode___parent].val = self; /* _parent on <var_node:AVisibility> */
3569 RET_LABEL1:(void)0;
3570 }
3571 }
3572 RET_LABEL:;
3573 }
3574 /* method parser_prod#AStdClassdef#n_visibility= for (self: Object, AVisibility) */
3575 void VIRTUAL_parser_prod__AStdClassdef__n_visibility_61d(val* self, val* p0) {
3576 parser_prod__AStdClassdef__n_visibility_61d(self, p0); /* Direct call parser_prod#AStdClassdef#n_visibility= on <self:Object(AStdClassdef)>*/
3577 RET_LABEL:;
3578 }
3579 /* method parser_prod#AStdClassdef#n_classkind= for (self: AStdClassdef, AClasskind) */
3580 void parser_prod__AStdClassdef__n_classkind_61d(val* self, val* p0) {
3581 val* var_node /* var node: AClasskind */;
3582 var_node = p0;
3583 self->attrs[COLOR_parser_nodes__AStdClassdef___n_classkind].val = var_node; /* _n_classkind on <self:AStdClassdef> */
3584 {
3585 { /* Inline parser_nodes#ANode#parent= (var_node,self) on <var_node:AClasskind> */
3586 var_node->attrs[COLOR_parser_nodes__ANode___parent].val = self; /* _parent on <var_node:AClasskind> */
3587 RET_LABEL1:(void)0;
3588 }
3589 }
3590 RET_LABEL:;
3591 }
3592 /* method parser_prod#AStdClassdef#n_classkind= for (self: Object, AClasskind) */
3593 void VIRTUAL_parser_prod__AStdClassdef__n_classkind_61d(val* self, val* p0) {
3594 parser_prod__AStdClassdef__n_classkind_61d(self, p0); /* Direct call parser_prod#AStdClassdef#n_classkind= on <self:Object(AStdClassdef)>*/
3595 RET_LABEL:;
3596 }
3597 /* method parser_prod#AStdClassdef#n_id= for (self: AStdClassdef, nullable TClassid) */
3598 void parser_prod__AStdClassdef__n_id_61d(val* self, val* p0) {
3599 val* var_node /* var node: nullable TClassid */;
3600 val* var /* : null */;
3601 short int var1 /* : Bool */;
3602 short int var2 /* : Bool */;
3603 val* var_other /* var other: nullable Object */;
3604 short int var4 /* : Bool */;
3605 short int var5 /* : Bool */;
3606 short int var6 /* : Bool */;
3607 var_node = p0;
3608 self->attrs[COLOR_parser_nodes__AStdClassdef___n_id].val = var_node; /* _n_id on <self:AStdClassdef> */
3609 var = NULL;
3610 if (var_node == NULL) {
3611 var1 = 0; /* is null */
3612 } else {
3613 var1 = 1; /* arg is null and recv is not */
3614 }
3615 if (0) {
3616 { /* Inline kernel#Object#!= (var_node,var) on <var_node:nullable TClassid> */
3617 var_other = var;
3618 {
3619 var5 = ((short int (*)(val*, val*))(var_node->class->vft[COLOR_kernel__Object___61d_61d]))(var_node, var_other) /* == on <var_node:nullable TClassid(TClassid)>*/;
3620 var4 = var5;
3621 }
3622 var6 = !var4;
3623 var2 = var6;
3624 goto RET_LABEL3;
3625 RET_LABEL3:(void)0;
3626 }
3627 var1 = var2;
3628 }
3629 if (var1){
3630 {
3631 { /* Inline parser_nodes#ANode#parent= (var_node,self) on <var_node:nullable TClassid(TClassid)> */
3632 var_node->attrs[COLOR_parser_nodes__ANode___parent].val = self; /* _parent on <var_node:nullable TClassid(TClassid)> */
3633 RET_LABEL7:(void)0;
3634 }
3635 }
3636 } else {
3637 }
3638 RET_LABEL:;
3639 }
3640 /* method parser_prod#AStdClassdef#n_id= for (self: Object, nullable TClassid) */
3641 void VIRTUAL_parser_prod__AStdClassdef__n_id_61d(val* self, val* p0) {
3642 parser_prod__AStdClassdef__n_id_61d(self, p0); /* Direct call parser_prod#AStdClassdef#n_id= on <self:Object(AStdClassdef)>*/
3643 RET_LABEL:;
3644 }
3645 /* method parser_prod#AStdClassdef#n_annotations= for (self: AStdClassdef, nullable AAnnotations) */
3646 void parser_prod__AStdClassdef__n_annotations_61d(val* self, val* p0) {
3647 val* var_node /* var node: nullable AAnnotations */;
3648 val* var /* : null */;
3649 short int var1 /* : Bool */;
3650 short int var2 /* : Bool */;
3651 val* var_other /* var other: nullable Object */;
3652 short int var4 /* : Bool */;
3653 short int var5 /* : Bool */;
3654 short int var6 /* : Bool */;
3655 var_node = p0;
3656 self->attrs[COLOR_parser_nodes__Prod___n_annotations].val = var_node; /* _n_annotations on <self:AStdClassdef> */
3657 var = NULL;
3658 if (var_node == NULL) {
3659 var1 = 0; /* is null */
3660 } else {
3661 var1 = 1; /* arg is null and recv is not */
3662 }
3663 if (0) {
3664 { /* Inline kernel#Object#!= (var_node,var) on <var_node:nullable AAnnotations> */
3665 var_other = var;
3666 {
3667 var5 = ((short int (*)(val*, val*))(var_node->class->vft[COLOR_kernel__Object___61d_61d]))(var_node, var_other) /* == on <var_node:nullable AAnnotations(AAnnotations)>*/;
3668 var4 = var5;
3669 }
3670 var6 = !var4;
3671 var2 = var6;
3672 goto RET_LABEL3;
3673 RET_LABEL3:(void)0;
3674 }
3675 var1 = var2;
3676 }
3677 if (var1){
3678 {
3679 { /* Inline parser_nodes#ANode#parent= (var_node,self) on <var_node:nullable AAnnotations(AAnnotations)> */
3680 var_node->attrs[COLOR_parser_nodes__ANode___parent].val = self; /* _parent on <var_node:nullable AAnnotations(AAnnotations)> */
3681 RET_LABEL7:(void)0;
3682 }
3683 }
3684 } else {
3685 }
3686 RET_LABEL:;
3687 }
3688 /* method parser_prod#AStdClassdef#n_annotations= for (self: Object, nullable AAnnotations) */
3689 void VIRTUAL_parser_prod__AStdClassdef__n_annotations_61d(val* self, val* p0) {
3690 parser_prod__AStdClassdef__n_annotations_61d(self, p0); /* Direct call parser_prod#AStdClassdef#n_annotations= on <self:Object(AStdClassdef)>*/
3691 RET_LABEL:;
3692 }
3693 /* method parser_prod#AStdClassdef#n_extern_code_block= for (self: AStdClassdef, nullable AExternCodeBlock) */
3694 void parser_prod__AStdClassdef__n_extern_code_block_61d(val* self, val* p0) {
3695 val* var_node /* var node: nullable AExternCodeBlock */;
3696 val* var /* : null */;
3697 short int var1 /* : Bool */;
3698 short int var2 /* : Bool */;
3699 val* var_other /* var other: nullable Object */;
3700 short int var4 /* : Bool */;
3701 short int var5 /* : Bool */;
3702 short int var6 /* : Bool */;
3703 var_node = p0;
3704 self->attrs[COLOR_parser_nodes__AStdClassdef___n_extern_code_block].val = var_node; /* _n_extern_code_block on <self:AStdClassdef> */
3705 var = NULL;
3706 if (var_node == NULL) {
3707 var1 = 0; /* is null */
3708 } else {
3709 var1 = 1; /* arg is null and recv is not */
3710 }
3711 if (0) {
3712 { /* Inline kernel#Object#!= (var_node,var) on <var_node:nullable AExternCodeBlock> */
3713 var_other = var;
3714 {
3715 var5 = ((short int (*)(val*, val*))(var_node->class->vft[COLOR_kernel__Object___61d_61d]))(var_node, var_other) /* == on <var_node:nullable AExternCodeBlock(AExternCodeBlock)>*/;
3716 var4 = var5;
3717 }
3718 var6 = !var4;
3719 var2 = var6;
3720 goto RET_LABEL3;
3721 RET_LABEL3:(void)0;
3722 }
3723 var1 = var2;
3724 }
3725 if (var1){
3726 {
3727 { /* Inline parser_nodes#ANode#parent= (var_node,self) on <var_node:nullable AExternCodeBlock(AExternCodeBlock)> */
3728 var_node->attrs[COLOR_parser_nodes__ANode___parent].val = self; /* _parent on <var_node:nullable AExternCodeBlock(AExternCodeBlock)> */
3729 RET_LABEL7:(void)0;
3730 }
3731 }
3732 } else {
3733 }
3734 RET_LABEL:;
3735 }
3736 /* method parser_prod#AStdClassdef#n_extern_code_block= for (self: Object, nullable AExternCodeBlock) */
3737 void VIRTUAL_parser_prod__AStdClassdef__n_extern_code_block_61d(val* self, val* p0) {
3738 parser_prod__AStdClassdef__n_extern_code_block_61d(self, p0); /* Direct call parser_prod#AStdClassdef#n_extern_code_block= on <self:Object(AStdClassdef)>*/
3739 RET_LABEL:;
3740 }
3741 /* method parser_prod#AStdClassdef#n_kwend= for (self: AStdClassdef, TKwend) */
3742 void parser_prod__AStdClassdef__n_kwend_61d(val* self, val* p0) {
3743 val* var_node /* var node: TKwend */;
3744 var_node = p0;
3745 self->attrs[COLOR_parser_nodes__AStdClassdef___n_kwend].val = var_node; /* _n_kwend on <self:AStdClassdef> */
3746 {
3747 { /* Inline parser_nodes#ANode#parent= (var_node,self) on <var_node:TKwend> */
3748 var_node->attrs[COLOR_parser_nodes__ANode___parent].val = self; /* _parent on <var_node:TKwend> */
3749 RET_LABEL1:(void)0;
3750 }
3751 }
3752 RET_LABEL:;
3753 }
3754 /* method parser_prod#AStdClassdef#n_kwend= for (self: Object, TKwend) */
3755 void VIRTUAL_parser_prod__AStdClassdef__n_kwend_61d(val* self, val* p0) {
3756 parser_prod__AStdClassdef__n_kwend_61d(self, p0); /* Direct call parser_prod#AStdClassdef#n_kwend= on <self:Object(AStdClassdef)>*/
3757 RET_LABEL:;
3758 }
3759 /* method parser_prod#AStdClassdef#visit_all for (self: AStdClassdef, Visitor) */
3760 void parser_prod__AStdClassdef__visit_all(val* self, val* p0) {
3761 val* var_v /* var v: Visitor */;
3762 val* var /* : nullable ADoc */;
3763 val* var1 /* : nullable TKwredef */;
3764 val* var2 /* : AVisibility */;
3765 val* var3 /* : AClasskind */;
3766 val* var4 /* : nullable TClassid */;
3767 val* var5 /* : ANodes[AFormaldef] */;
3768 val* var7 /* : ANodes[AFormaldef] */;
3769 val* var8 /* : nullable AAnnotations */;
3770 val* var9 /* : nullable AExternCodeBlock */;
3771 val* var10 /* : ANodes[ASuperclass] */;
3772 val* var12 /* : ANodes[ASuperclass] */;
3773 val* var13 /* : ANodes[APropdef] */;
3774 val* var15 /* : ANodes[APropdef] */;
3775 val* var16 /* : TKwend */;
3776 var_v = p0;
3777 var = self->attrs[COLOR_parser_nodes__AStdClassdef___n_doc].val; /* _n_doc on <self:AStdClassdef> */
3778 {
3779 parser_nodes__Visitor__enter_visit(var_v, var); /* Direct call parser_nodes#Visitor#enter_visit on <var_v:Visitor>*/
3780 }
3781 var1 = self->attrs[COLOR_parser_nodes__AStdClassdef___n_kwredef].val; /* _n_kwredef on <self:AStdClassdef> */
3782 {
3783 parser_nodes__Visitor__enter_visit(var_v, var1); /* Direct call parser_nodes#Visitor#enter_visit on <var_v:Visitor>*/
3784 }
3785 var2 = self->attrs[COLOR_parser_nodes__AStdClassdef___n_visibility].val; /* _n_visibility on <self:AStdClassdef> */
3786 if (unlikely(var2 == NULL)) {
3787 PRINT_ERROR("Runtime error: %s", "Uninitialized attribute _n_visibility");
3788 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 504);
3789 show_backtrace(1);
3790 }
3791 {
3792 parser_nodes__Visitor__enter_visit(var_v, var2); /* Direct call parser_nodes#Visitor#enter_visit on <var_v:Visitor>*/
3793 }
3794 var3 = self->attrs[COLOR_parser_nodes__AStdClassdef___n_classkind].val; /* _n_classkind on <self:AStdClassdef> */
3795 if (unlikely(var3 == NULL)) {
3796 PRINT_ERROR("Runtime error: %s", "Uninitialized attribute _n_classkind");
3797 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 505);
3798 show_backtrace(1);
3799 }
3800 {
3801 parser_nodes__Visitor__enter_visit(var_v, var3); /* Direct call parser_nodes#Visitor#enter_visit on <var_v:Visitor>*/
3802 }
3803 var4 = self->attrs[COLOR_parser_nodes__AStdClassdef___n_id].val; /* _n_id on <self:AStdClassdef> */
3804 {
3805 parser_nodes__Visitor__enter_visit(var_v, var4); /* Direct call parser_nodes#Visitor#enter_visit on <var_v:Visitor>*/
3806 }
3807 {
3808 { /* Inline parser_nodes#AStdClassdef#n_formaldefs (self) on <self:AStdClassdef> */
3809 var7 = self->attrs[COLOR_parser_nodes__AStdClassdef___n_formaldefs].val; /* _n_formaldefs on <self:AStdClassdef> */
3810 if (unlikely(var7 == NULL)) {
3811 PRINT_ERROR("Runtime error: %s", "Uninitialized attribute _n_formaldefs");
3812 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_nodes.nit", 824);
3813 show_backtrace(1);
3814 }
3815 var5 = var7;
3816 RET_LABEL6:(void)0;
3817 }
3818 }
3819 {
3820 parser_nodes__ANodes__visit_all(var5, var_v); /* Direct call parser_nodes#ANodes#visit_all on <var5:ANodes[AFormaldef]>*/
3821 }
3822 var8 = self->attrs[COLOR_parser_nodes__Prod___n_annotations].val; /* _n_annotations on <self:AStdClassdef> */
3823 {
3824 parser_nodes__Visitor__enter_visit(var_v, var8); /* Direct call parser_nodes#Visitor#enter_visit on <var_v:Visitor>*/
3825 }
3826 var9 = self->attrs[COLOR_parser_nodes__AStdClassdef___n_extern_code_block].val; /* _n_extern_code_block on <self:AStdClassdef> */
3827 {
3828 parser_nodes__Visitor__enter_visit(var_v, var9); /* Direct call parser_nodes#Visitor#enter_visit on <var_v:Visitor>*/
3829 }
3830 {
3831 { /* Inline parser_nodes#AStdClassdef#n_superclasses (self) on <self:AStdClassdef> */
3832 var12 = self->attrs[COLOR_parser_nodes__AStdClassdef___n_superclasses].val; /* _n_superclasses on <self:AStdClassdef> */
3833 if (unlikely(var12 == NULL)) {
3834 PRINT_ERROR("Runtime error: %s", "Uninitialized attribute _n_superclasses");
3835 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_nodes.nit", 828);
3836 show_backtrace(1);
3837 }
3838 var10 = var12;
3839 RET_LABEL11:(void)0;
3840 }
3841 }
3842 {
3843 parser_nodes__ANodes__visit_all(var10, var_v); /* Direct call parser_nodes#ANodes#visit_all on <var10:ANodes[ASuperclass]>*/
3844 }
3845 {
3846 { /* Inline parser_nodes#AClassdef#n_propdefs (self) on <self:AStdClassdef> */
3847 var15 = self->attrs[COLOR_parser_nodes__AClassdef___n_propdefs].val; /* _n_propdefs on <self:AStdClassdef> */
3848 if (unlikely(var15 == NULL)) {
3849 PRINT_ERROR("Runtime error: %s", "Uninitialized attribute _n_propdefs");
3850 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_nodes.nit", 802);
3851 show_backtrace(1);
3852 }
3853 var13 = var15;
3854 RET_LABEL14:(void)0;
3855 }
3856 }
3857 {
3858 parser_nodes__ANodes__visit_all(var13, var_v); /* Direct call parser_nodes#ANodes#visit_all on <var13:ANodes[APropdef]>*/
3859 }
3860 var16 = self->attrs[COLOR_parser_nodes__AStdClassdef___n_kwend].val; /* _n_kwend on <self:AStdClassdef> */
3861 if (unlikely(var16 == NULL)) {
3862 PRINT_ERROR("Runtime error: %s", "Uninitialized attribute _n_kwend");
3863 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 512);
3864 show_backtrace(1);
3865 }
3866 {
3867 parser_nodes__Visitor__enter_visit(var_v, var16); /* Direct call parser_nodes#Visitor#enter_visit on <var_v:Visitor>*/
3868 }
3869 RET_LABEL:;
3870 }
3871 /* method parser_prod#AStdClassdef#visit_all for (self: Object, Visitor) */
3872 void VIRTUAL_parser_prod__AStdClassdef__visit_all(val* self, val* p0) {
3873 parser_prod__AStdClassdef__visit_all(self, p0); /* Direct call parser_prod#AStdClassdef#visit_all on <self:Object(AStdClassdef)>*/
3874 RET_LABEL:;
3875 }
3876 /* method parser_prod#ATopClassdef#init_atopclassdef for (self: ATopClassdef, Collection[Object]) */
3877 void parser_prod__ATopClassdef__init_atopclassdef(val* self, val* p0) {
3878 val* var_n_propdefs /* var n_propdefs: Collection[Object] */;
3879 val* var /* : ANodes[APropdef] */;
3880 val* var2 /* : ANodes[APropdef] */;
3881 var_n_propdefs = p0;
3882 {
3883 { /* Inline parser_nodes#AClassdef#n_propdefs (self) on <self:ATopClassdef> */
3884 var2 = self->attrs[COLOR_parser_nodes__AClassdef___n_propdefs].val; /* _n_propdefs on <self:ATopClassdef> */
3885 if (unlikely(var2 == NULL)) {
3886 PRINT_ERROR("Runtime error: %s", "Uninitialized attribute _n_propdefs");
3887 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_nodes.nit", 802);
3888 show_backtrace(1);
3889 }
3890 var = var2;
3891 RET_LABEL1:(void)0;
3892 }
3893 }
3894 {
3895 parser_nodes__ANodes__unsafe_add_all(var, var_n_propdefs); /* Direct call parser_nodes#ANodes#unsafe_add_all on <var:ANodes[APropdef]>*/
3896 }
3897 RET_LABEL:;
3898 }
3899 /* method parser_prod#ATopClassdef#init_atopclassdef for (self: Object, Collection[Object]) */
3900 void VIRTUAL_parser_prod__ATopClassdef__init_atopclassdef(val* self, val* p0) {
3901 parser_prod__ATopClassdef__init_atopclassdef(self, p0); /* Direct call parser_prod#ATopClassdef#init_atopclassdef on <self:Object(ATopClassdef)>*/
3902 RET_LABEL:;
3903 }
3904 /* method parser_prod#ATopClassdef#replace_child for (self: ATopClassdef, ANode, nullable ANode) */
3905 void parser_prod__ATopClassdef__replace_child(val* self, val* p0, val* p1) {
3906 val* var_old_child /* var old_child: ANode */;
3907 val* var_new_child /* var new_child: nullable ANode */;
3908 val* var /* : ANodes[APropdef] */;
3909 val* var2 /* : ANodes[APropdef] */;
3910 short int var3 /* : Bool */;
3911 var_old_child = p0;
3912 var_new_child = p1;
3913 {
3914 { /* Inline parser_nodes#AClassdef#n_propdefs (self) on <self:ATopClassdef> */
3915 var2 = self->attrs[COLOR_parser_nodes__AClassdef___n_propdefs].val; /* _n_propdefs on <self:ATopClassdef> */
3916 if (unlikely(var2 == NULL)) {
3917 PRINT_ERROR("Runtime error: %s", "Uninitialized attribute _n_propdefs");
3918 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_nodes.nit", 802);
3919 show_backtrace(1);
3920 }
3921 var = var2;
3922 RET_LABEL1:(void)0;
3923 }
3924 }
3925 {
3926 var3 = parser_nodes__ANodes__replace_child(var, var_old_child, var_new_child);
3927 }
3928 if (var3){
3929 goto RET_LABEL;
3930 } else {
3931 }
3932 RET_LABEL:;
3933 }
3934 /* method parser_prod#ATopClassdef#replace_child for (self: Object, ANode, nullable ANode) */
3935 void VIRTUAL_parser_prod__ATopClassdef__replace_child(val* self, val* p0, val* p1) {
3936 parser_prod__ATopClassdef__replace_child(self, p0, p1); /* Direct call parser_prod#ATopClassdef#replace_child on <self:Object(ATopClassdef)>*/
3937 RET_LABEL:;
3938 }
3939 /* method parser_prod#ATopClassdef#visit_all for (self: ATopClassdef, Visitor) */
3940 void parser_prod__ATopClassdef__visit_all(val* self, val* p0) {
3941 val* var_v /* var v: Visitor */;
3942 val* var /* : ANodes[APropdef] */;
3943 val* var2 /* : ANodes[APropdef] */;
3944 var_v = p0;
3945 {
3946 { /* Inline parser_nodes#AClassdef#n_propdefs (self) on <self:ATopClassdef> */
3947 var2 = self->attrs[COLOR_parser_nodes__AClassdef___n_propdefs].val; /* _n_propdefs on <self:ATopClassdef> */
3948 if (unlikely(var2 == NULL)) {
3949 PRINT_ERROR("Runtime error: %s", "Uninitialized attribute _n_propdefs");
3950 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_nodes.nit", 802);
3951 show_backtrace(1);
3952 }
3953 var = var2;
3954 RET_LABEL1:(void)0;
3955 }
3956 }
3957 {
3958 parser_nodes__ANodes__visit_all(var, var_v); /* Direct call parser_nodes#ANodes#visit_all on <var:ANodes[APropdef]>*/
3959 }
3960 RET_LABEL:;
3961 }
3962 /* method parser_prod#ATopClassdef#visit_all for (self: Object, Visitor) */
3963 void VIRTUAL_parser_prod__ATopClassdef__visit_all(val* self, val* p0) {
3964 parser_prod__ATopClassdef__visit_all(self, p0); /* Direct call parser_prod#ATopClassdef#visit_all on <self:Object(ATopClassdef)>*/
3965 RET_LABEL:;
3966 }
3967 /* method parser_prod#AMainClassdef#init_amainclassdef for (self: AMainClassdef, Collection[Object]) */
3968 void parser_prod__AMainClassdef__init_amainclassdef(val* self, val* p0) {
3969 val* var_n_propdefs /* var n_propdefs: Collection[Object] */;
3970 val* var /* : ANodes[APropdef] */;
3971 val* var2 /* : ANodes[APropdef] */;
3972 var_n_propdefs = p0;
3973 {
3974 { /* Inline parser_nodes#AClassdef#n_propdefs (self) on <self:AMainClassdef> */
3975 var2 = self->attrs[COLOR_parser_nodes__AClassdef___n_propdefs].val; /* _n_propdefs on <self:AMainClassdef> */
3976 if (unlikely(var2 == NULL)) {
3977 PRINT_ERROR("Runtime error: %s", "Uninitialized attribute _n_propdefs");
3978 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_nodes.nit", 802);
3979 show_backtrace(1);
3980 }
3981 var = var2;
3982 RET_LABEL1:(void)0;
3983 }
3984 }
3985 {
3986 parser_nodes__ANodes__unsafe_add_all(var, var_n_propdefs); /* Direct call parser_nodes#ANodes#unsafe_add_all on <var:ANodes[APropdef]>*/
3987 }
3988 RET_LABEL:;
3989 }
3990 /* method parser_prod#AMainClassdef#init_amainclassdef for (self: Object, Collection[Object]) */
3991 void VIRTUAL_parser_prod__AMainClassdef__init_amainclassdef(val* self, val* p0) {
3992 parser_prod__AMainClassdef__init_amainclassdef(self, p0); /* Direct call parser_prod#AMainClassdef#init_amainclassdef on <self:Object(AMainClassdef)>*/
3993 RET_LABEL:;
3994 }
3995 /* method parser_prod#AMainClassdef#replace_child for (self: AMainClassdef, ANode, nullable ANode) */
3996 void parser_prod__AMainClassdef__replace_child(val* self, val* p0, val* p1) {
3997 val* var_old_child /* var old_child: ANode */;
3998 val* var_new_child /* var new_child: nullable ANode */;
3999 val* var /* : ANodes[APropdef] */;
4000 val* var2 /* : ANodes[APropdef] */;
4001 short int var3 /* : Bool */;
4002 var_old_child = p0;
4003 var_new_child = p1;
4004 {
4005 { /* Inline parser_nodes#AClassdef#n_propdefs (self) on <self:AMainClassdef> */
4006 var2 = self->attrs[COLOR_parser_nodes__AClassdef___n_propdefs].val; /* _n_propdefs on <self:AMainClassdef> */
4007 if (unlikely(var2 == NULL)) {
4008 PRINT_ERROR("Runtime error: %s", "Uninitialized attribute _n_propdefs");
4009 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_nodes.nit", 802);
4010 show_backtrace(1);
4011 }
4012 var = var2;
4013 RET_LABEL1:(void)0;
4014 }
4015 }
4016 {
4017 var3 = parser_nodes__ANodes__replace_child(var, var_old_child, var_new_child);
4018 }
4019 if (var3){
4020 goto RET_LABEL;
4021 } else {
4022 }
4023 RET_LABEL:;
4024 }
4025 /* method parser_prod#AMainClassdef#replace_child for (self: Object, ANode, nullable ANode) */
4026 void VIRTUAL_parser_prod__AMainClassdef__replace_child(val* self, val* p0, val* p1) {
4027 parser_prod__AMainClassdef__replace_child(self, p0, p1); /* Direct call parser_prod#AMainClassdef#replace_child on <self:Object(AMainClassdef)>*/
4028 RET_LABEL:;
4029 }
4030 /* method parser_prod#AMainClassdef#visit_all for (self: AMainClassdef, Visitor) */
4031 void parser_prod__AMainClassdef__visit_all(val* self, val* p0) {
4032 val* var_v /* var v: Visitor */;
4033 val* var /* : ANodes[APropdef] */;
4034 val* var2 /* : ANodes[APropdef] */;
4035 var_v = p0;
4036 {
4037 { /* Inline parser_nodes#AClassdef#n_propdefs (self) on <self:AMainClassdef> */
4038 var2 = self->attrs[COLOR_parser_nodes__AClassdef___n_propdefs].val; /* _n_propdefs on <self:AMainClassdef> */
4039 if (unlikely(var2 == NULL)) {
4040 PRINT_ERROR("Runtime error: %s", "Uninitialized attribute _n_propdefs");
4041 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_nodes.nit", 802);
4042 show_backtrace(1);
4043 }
4044 var = var2;
4045 RET_LABEL1:(void)0;
4046 }
4047 }
4048 {
4049 parser_nodes__ANodes__visit_all(var, var_v); /* Direct call parser_nodes#ANodes#visit_all on <var:ANodes[APropdef]>*/
4050 }
4051 RET_LABEL:;
4052 }
4053 /* method parser_prod#AMainClassdef#visit_all for (self: Object, Visitor) */
4054 void VIRTUAL_parser_prod__AMainClassdef__visit_all(val* self, val* p0) {
4055 parser_prod__AMainClassdef__visit_all(self, p0); /* Direct call parser_prod#AMainClassdef#visit_all on <self:Object(AMainClassdef)>*/
4056 RET_LABEL:;
4057 }
4058 /* method parser_prod#AConcreteClasskind#init_aconcreteclasskind for (self: AConcreteClasskind, nullable TKwclass) */
4059 void parser_prod__AConcreteClasskind__init_aconcreteclasskind(val* self, val* p0) {
4060 val* var_n_kwclass /* var n_kwclass: nullable TKwclass */;
4061 var_n_kwclass = p0;
4062 if (unlikely(var_n_kwclass == NULL)) {
4063 PRINT_ERROR("Runtime error: %s", "Cast failed");
4064 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 560);
4065 show_backtrace(1);
4066 }
4067 self->attrs[COLOR_parser_nodes__AConcreteClasskind___n_kwclass].val = var_n_kwclass; /* _n_kwclass on <self:AConcreteClasskind> */
4068 if (var_n_kwclass == NULL) {
4069 PRINT_ERROR("Runtime error: %s", "Receiver is null");
4070 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 561);
4071 show_backtrace(1);
4072 } else {
4073 { /* Inline parser_nodes#ANode#parent= (var_n_kwclass,self) on <var_n_kwclass:nullable TKwclass> */
4074 if (unlikely(var_n_kwclass == NULL)) {
4075 PRINT_ERROR("Runtime error: %s", "Receiver is null");
4076 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_nodes.nit", 38);
4077 show_backtrace(1);
4078 }
4079 var_n_kwclass->attrs[COLOR_parser_nodes__ANode___parent].val = self; /* _parent on <var_n_kwclass:nullable TKwclass> */
4080 RET_LABEL1:(void)0;
4081 }
4082 }
4083 RET_LABEL:;
4084 }
4085 /* method parser_prod#AConcreteClasskind#init_aconcreteclasskind for (self: Object, nullable TKwclass) */
4086 void VIRTUAL_parser_prod__AConcreteClasskind__init_aconcreteclasskind(val* self, val* p0) {
4087 parser_prod__AConcreteClasskind__init_aconcreteclasskind(self, p0); /* Direct call parser_prod#AConcreteClasskind#init_aconcreteclasskind on <self:Object(AConcreteClasskind)>*/
4088 RET_LABEL:;
4089 }
4090 /* method parser_prod#AConcreteClasskind#replace_child for (self: AConcreteClasskind, ANode, nullable ANode) */
4091 void parser_prod__AConcreteClasskind__replace_child(val* self, val* p0, val* p1) {
4092 val* var_old_child /* var old_child: ANode */;
4093 val* var_new_child /* var new_child: nullable ANode */;
4094 val* var /* : TKwclass */;
4095 short int var1 /* : Bool */;
4096 short int var2 /* : Bool */;
4097 val* var_other /* var other: nullable Object */;
4098 short int var4 /* : Bool */;
4099 short int var6 /* : Bool */;
4100 short int var7 /* : Bool */;
4101 int cltype;
4102 int idtype;
4103 const char* var_class_name;
4104 var_old_child = p0;
4105 var_new_child = p1;
4106 var = self->attrs[COLOR_parser_nodes__AConcreteClasskind___n_kwclass].val; /* _n_kwclass on <self:AConcreteClasskind> */
4107 if (unlikely(var == NULL)) {
4108 PRINT_ERROR("Runtime error: %s", "Uninitialized attribute _n_kwclass");
4109 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 566);
4110 show_backtrace(1);
4111 }
4112 {
4113 { /* Inline kernel#Object#== (var,var_old_child) on <var:TKwclass> */
4114 var_other = var_old_child;
4115 {
4116 { /* Inline kernel#Object#is_same_instance (var,var_other) on <var:TKwclass> */
4117 var6 = var == var_other;
4118 var4 = var6;
4119 goto RET_LABEL5;
4120 RET_LABEL5:(void)0;
4121 }
4122 }
4123 var2 = var4;
4124 goto RET_LABEL3;
4125 RET_LABEL3:(void)0;
4126 }
4127 var1 = var2;
4128 }
4129 if (var1){
4130 /* <var_new_child:nullable ANode> isa TKwclass */
4131 cltype = type_parser_nodes__TKwclass.color;
4132 idtype = type_parser_nodes__TKwclass.id;
4133 if(var_new_child == NULL) {
4134 var7 = 0;
4135 } else {
4136 if(cltype >= var_new_child->type->table_size) {
4137 var7 = 0;
4138 } else {
4139 var7 = var_new_child->type->type_table[cltype] == idtype;
4140 }
4141 }
4142 if (unlikely(!var7)) {
4143 var_class_name = var_new_child == NULL ? "null" : var_new_child->type->name;
4144 PRINT_ERROR("Runtime error: Cast failed. Expected `%s`, got `%s`", "TKwclass", var_class_name);
4145 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 567);
4146 show_backtrace(1);
4147 }
4148 {
4149 parser_prod__AConcreteClasskind__n_kwclass_61d(self, var_new_child); /* Direct call parser_prod#AConcreteClasskind#n_kwclass= on <self:AConcreteClasskind>*/
4150 }
4151 goto RET_LABEL;
4152 } else {
4153 }
4154 RET_LABEL:;
4155 }
4156 /* method parser_prod#AConcreteClasskind#replace_child for (self: Object, ANode, nullable ANode) */
4157 void VIRTUAL_parser_prod__AConcreteClasskind__replace_child(val* self, val* p0, val* p1) {
4158 parser_prod__AConcreteClasskind__replace_child(self, p0, p1); /* Direct call parser_prod#AConcreteClasskind#replace_child on <self:Object(AConcreteClasskind)>*/
4159 RET_LABEL:;
4160 }
4161 /* method parser_prod#AConcreteClasskind#n_kwclass= for (self: AConcreteClasskind, TKwclass) */
4162 void parser_prod__AConcreteClasskind__n_kwclass_61d(val* self, val* p0) {
4163 val* var_node /* var node: TKwclass */;
4164 var_node = p0;
4165 self->attrs[COLOR_parser_nodes__AConcreteClasskind___n_kwclass].val = var_node; /* _n_kwclass on <self:AConcreteClasskind> */
4166 {
4167 { /* Inline parser_nodes#ANode#parent= (var_node,self) on <var_node:TKwclass> */
4168 var_node->attrs[COLOR_parser_nodes__ANode___parent].val = self; /* _parent on <var_node:TKwclass> */
4169 RET_LABEL1:(void)0;
4170 }
4171 }
4172 RET_LABEL:;
4173 }
4174 /* method parser_prod#AConcreteClasskind#n_kwclass= for (self: Object, TKwclass) */
4175 void VIRTUAL_parser_prod__AConcreteClasskind__n_kwclass_61d(val* self, val* p0) {
4176 parser_prod__AConcreteClasskind__n_kwclass_61d(self, p0); /* Direct call parser_prod#AConcreteClasskind#n_kwclass= on <self:Object(AConcreteClasskind)>*/
4177 RET_LABEL:;
4178 }
4179 /* method parser_prod#AConcreteClasskind#visit_all for (self: AConcreteClasskind, Visitor) */
4180 void parser_prod__AConcreteClasskind__visit_all(val* self, val* p0) {
4181 val* var_v /* var v: Visitor */;
4182 val* var /* : TKwclass */;
4183 var_v = p0;
4184 var = self->attrs[COLOR_parser_nodes__AConcreteClasskind___n_kwclass].val; /* _n_kwclass on <self:AConcreteClasskind> */
4185 if (unlikely(var == NULL)) {
4186 PRINT_ERROR("Runtime error: %s", "Uninitialized attribute _n_kwclass");
4187 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 581);
4188 show_backtrace(1);
4189 }
4190 {
4191 parser_nodes__Visitor__enter_visit(var_v, var); /* Direct call parser_nodes#Visitor#enter_visit on <var_v:Visitor>*/
4192 }
4193 RET_LABEL:;
4194 }
4195 /* method parser_prod#AConcreteClasskind#visit_all for (self: Object, Visitor) */
4196 void VIRTUAL_parser_prod__AConcreteClasskind__visit_all(val* self, val* p0) {
4197 parser_prod__AConcreteClasskind__visit_all(self, p0); /* Direct call parser_prod#AConcreteClasskind#visit_all on <self:Object(AConcreteClasskind)>*/
4198 RET_LABEL:;
4199 }
4200 /* method parser_prod#AAbstractClasskind#init_aabstractclasskind for (self: AAbstractClasskind, nullable TKwabstract, nullable TKwclass) */
4201 void parser_prod__AAbstractClasskind__init_aabstractclasskind(val* self, val* p0, val* p1) {
4202 val* var_n_kwabstract /* var n_kwabstract: nullable TKwabstract */;
4203 val* var_n_kwclass /* var n_kwclass: nullable TKwclass */;
4204 var_n_kwabstract = p0;
4205 var_n_kwclass = p1;
4206 if (unlikely(var_n_kwabstract == NULL)) {
4207 PRINT_ERROR("Runtime error: %s", "Cast failed");
4208 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 590);
4209 show_backtrace(1);
4210 }
4211 self->attrs[COLOR_parser_nodes__AAbstractClasskind___n_kwabstract].val = var_n_kwabstract; /* _n_kwabstract on <self:AAbstractClasskind> */
4212 if (var_n_kwabstract == NULL) {
4213 PRINT_ERROR("Runtime error: %s", "Receiver is null");
4214 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 591);
4215 show_backtrace(1);
4216 } else {
4217 { /* Inline parser_nodes#ANode#parent= (var_n_kwabstract,self) on <var_n_kwabstract:nullable TKwabstract> */
4218 if (unlikely(var_n_kwabstract == NULL)) {
4219 PRINT_ERROR("Runtime error: %s", "Receiver is null");
4220 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_nodes.nit", 38);
4221 show_backtrace(1);
4222 }
4223 var_n_kwabstract->attrs[COLOR_parser_nodes__ANode___parent].val = self; /* _parent on <var_n_kwabstract:nullable TKwabstract> */
4224 RET_LABEL1:(void)0;
4225 }
4226 }
4227 if (unlikely(var_n_kwclass == NULL)) {
4228 PRINT_ERROR("Runtime error: %s", "Cast failed");
4229 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 592);
4230 show_backtrace(1);
4231 }
4232 self->attrs[COLOR_parser_nodes__AAbstractClasskind___n_kwclass].val = var_n_kwclass; /* _n_kwclass on <self:AAbstractClasskind> */
4233 if (var_n_kwclass == NULL) {
4234 PRINT_ERROR("Runtime error: %s", "Receiver is null");
4235 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 593);
4236 show_backtrace(1);
4237 } else {
4238 { /* Inline parser_nodes#ANode#parent= (var_n_kwclass,self) on <var_n_kwclass:nullable TKwclass> */
4239 if (unlikely(var_n_kwclass == NULL)) {
4240 PRINT_ERROR("Runtime error: %s", "Receiver is null");
4241 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_nodes.nit", 38);
4242 show_backtrace(1);
4243 }
4244 var_n_kwclass->attrs[COLOR_parser_nodes__ANode___parent].val = self; /* _parent on <var_n_kwclass:nullable TKwclass> */
4245 RET_LABEL2:(void)0;
4246 }
4247 }
4248 RET_LABEL:;
4249 }
4250 /* method parser_prod#AAbstractClasskind#init_aabstractclasskind for (self: Object, nullable TKwabstract, nullable TKwclass) */
4251 void VIRTUAL_parser_prod__AAbstractClasskind__init_aabstractclasskind(val* self, val* p0, val* p1) {
4252 parser_prod__AAbstractClasskind__init_aabstractclasskind(self, p0, p1); /* Direct call parser_prod#AAbstractClasskind#init_aabstractclasskind on <self:Object(AAbstractClasskind)>*/
4253 RET_LABEL:;
4254 }
4255 /* method parser_prod#AAbstractClasskind#replace_child for (self: AAbstractClasskind, ANode, nullable ANode) */
4256 void parser_prod__AAbstractClasskind__replace_child(val* self, val* p0, val* p1) {
4257 val* var_old_child /* var old_child: ANode */;
4258 val* var_new_child /* var new_child: nullable ANode */;
4259 val* var /* : TKwabstract */;
4260 short int var1 /* : Bool */;
4261 short int var2 /* : Bool */;
4262 val* var_other /* var other: nullable Object */;
4263 short int var4 /* : Bool */;
4264 short int var6 /* : Bool */;
4265 short int var7 /* : Bool */;
4266 int cltype;
4267 int idtype;
4268 const char* var_class_name;
4269 val* var8 /* : TKwclass */;
4270 short int var9 /* : Bool */;
4271 short int var10 /* : Bool */;
4272 short int var12 /* : Bool */;
4273 short int var14 /* : Bool */;
4274 short int var15 /* : Bool */;
4275 int cltype16;
4276 int idtype17;
4277 const char* var_class_name18;
4278 var_old_child = p0;
4279 var_new_child = p1;
4280 var = self->attrs[COLOR_parser_nodes__AAbstractClasskind___n_kwabstract].val; /* _n_kwabstract on <self:AAbstractClasskind> */
4281 if (unlikely(var == NULL)) {
4282 PRINT_ERROR("Runtime error: %s", "Uninitialized attribute _n_kwabstract");
4283 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 598);
4284 show_backtrace(1);
4285 }
4286 {
4287 { /* Inline kernel#Object#== (var,var_old_child) on <var:TKwabstract> */
4288 var_other = var_old_child;
4289 {
4290 { /* Inline kernel#Object#is_same_instance (var,var_other) on <var:TKwabstract> */
4291 var6 = var == var_other;
4292 var4 = var6;
4293 goto RET_LABEL5;
4294 RET_LABEL5:(void)0;
4295 }
4296 }
4297 var2 = var4;
4298 goto RET_LABEL3;
4299 RET_LABEL3:(void)0;
4300 }
4301 var1 = var2;
4302 }
4303 if (var1){
4304 /* <var_new_child:nullable ANode> isa TKwabstract */
4305 cltype = type_parser_nodes__TKwabstract.color;
4306 idtype = type_parser_nodes__TKwabstract.id;
4307 if(var_new_child == NULL) {
4308 var7 = 0;
4309 } else {
4310 if(cltype >= var_new_child->type->table_size) {
4311 var7 = 0;
4312 } else {
4313 var7 = var_new_child->type->type_table[cltype] == idtype;
4314 }
4315 }
4316 if (unlikely(!var7)) {
4317 var_class_name = var_new_child == NULL ? "null" : var_new_child->type->name;
4318 PRINT_ERROR("Runtime error: Cast failed. Expected `%s`, got `%s`", "TKwabstract", var_class_name);
4319 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 599);
4320 show_backtrace(1);
4321 }
4322 {
4323 parser_prod__AAbstractClasskind__n_kwabstract_61d(self, var_new_child); /* Direct call parser_prod#AAbstractClasskind#n_kwabstract= on <self:AAbstractClasskind>*/
4324 }
4325 goto RET_LABEL;
4326 } else {
4327 }
4328 var8 = self->attrs[COLOR_parser_nodes__AAbstractClasskind___n_kwclass].val; /* _n_kwclass on <self:AAbstractClasskind> */
4329 if (unlikely(var8 == NULL)) {
4330 PRINT_ERROR("Runtime error: %s", "Uninitialized attribute _n_kwclass");
4331 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 602);
4332 show_backtrace(1);
4333 }
4334 {
4335 { /* Inline kernel#Object#== (var8,var_old_child) on <var8:TKwclass> */
4336 var_other = var_old_child;
4337 {
4338 { /* Inline kernel#Object#is_same_instance (var8,var_other) on <var8:TKwclass> */
4339 var14 = var8 == var_other;
4340 var12 = var14;
4341 goto RET_LABEL13;
4342 RET_LABEL13:(void)0;
4343 }
4344 }
4345 var10 = var12;
4346 goto RET_LABEL11;
4347 RET_LABEL11:(void)0;
4348 }
4349 var9 = var10;
4350 }
4351 if (var9){
4352 /* <var_new_child:nullable ANode> isa TKwclass */
4353 cltype16 = type_parser_nodes__TKwclass.color;
4354 idtype17 = type_parser_nodes__TKwclass.id;
4355 if(var_new_child == NULL) {
4356 var15 = 0;
4357 } else {
4358 if(cltype16 >= var_new_child->type->table_size) {
4359 var15 = 0;
4360 } else {
4361 var15 = var_new_child->type->type_table[cltype16] == idtype17;
4362 }
4363 }
4364 if (unlikely(!var15)) {
4365 var_class_name18 = var_new_child == NULL ? "null" : var_new_child->type->name;
4366 PRINT_ERROR("Runtime error: Cast failed. Expected `%s`, got `%s`", "TKwclass", var_class_name18);
4367 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 603);
4368 show_backtrace(1);
4369 }
4370 {
4371 parser_prod__AAbstractClasskind__n_kwclass_61d(self, var_new_child); /* Direct call parser_prod#AAbstractClasskind#n_kwclass= on <self:AAbstractClasskind>*/
4372 }
4373 goto RET_LABEL;
4374 } else {
4375 }
4376 RET_LABEL:;
4377 }
4378 /* method parser_prod#AAbstractClasskind#replace_child for (self: Object, ANode, nullable ANode) */
4379 void VIRTUAL_parser_prod__AAbstractClasskind__replace_child(val* self, val* p0, val* p1) {
4380 parser_prod__AAbstractClasskind__replace_child(self, p0, p1); /* Direct call parser_prod#AAbstractClasskind#replace_child on <self:Object(AAbstractClasskind)>*/
4381 RET_LABEL:;
4382 }
4383 /* method parser_prod#AAbstractClasskind#n_kwabstract= for (self: AAbstractClasskind, TKwabstract) */
4384 void parser_prod__AAbstractClasskind__n_kwabstract_61d(val* self, val* p0) {
4385 val* var_node /* var node: TKwabstract */;
4386 var_node = p0;
4387 self->attrs[COLOR_parser_nodes__AAbstractClasskind___n_kwabstract].val = var_node; /* _n_kwabstract on <self:AAbstractClasskind> */
4388 {
4389 { /* Inline parser_nodes#ANode#parent= (var_node,self) on <var_node:TKwabstract> */
4390 var_node->attrs[COLOR_parser_nodes__ANode___parent].val = self; /* _parent on <var_node:TKwabstract> */
4391 RET_LABEL1:(void)0;
4392 }
4393 }
4394 RET_LABEL:;
4395 }
4396 /* method parser_prod#AAbstractClasskind#n_kwabstract= for (self: Object, TKwabstract) */
4397 void VIRTUAL_parser_prod__AAbstractClasskind__n_kwabstract_61d(val* self, val* p0) {
4398 parser_prod__AAbstractClasskind__n_kwabstract_61d(self, p0); /* Direct call parser_prod#AAbstractClasskind#n_kwabstract= on <self:Object(AAbstractClasskind)>*/
4399 RET_LABEL:;
4400 }
4401 /* method parser_prod#AAbstractClasskind#n_kwclass= for (self: AAbstractClasskind, TKwclass) */
4402 void parser_prod__AAbstractClasskind__n_kwclass_61d(val* self, val* p0) {
4403 val* var_node /* var node: TKwclass */;
4404 var_node = p0;
4405 self->attrs[COLOR_parser_nodes__AAbstractClasskind___n_kwclass].val = var_node; /* _n_kwclass on <self:AAbstractClasskind> */
4406 {
4407 { /* Inline parser_nodes#ANode#parent= (var_node,self) on <var_node:TKwclass> */
4408 var_node->attrs[COLOR_parser_nodes__ANode___parent].val = self; /* _parent on <var_node:TKwclass> */
4409 RET_LABEL1:(void)0;
4410 }
4411 }
4412 RET_LABEL:;
4413 }
4414 /* method parser_prod#AAbstractClasskind#n_kwclass= for (self: Object, TKwclass) */
4415 void VIRTUAL_parser_prod__AAbstractClasskind__n_kwclass_61d(val* self, val* p0) {
4416 parser_prod__AAbstractClasskind__n_kwclass_61d(self, p0); /* Direct call parser_prod#AAbstractClasskind#n_kwclass= on <self:Object(AAbstractClasskind)>*/
4417 RET_LABEL:;
4418 }
4419 /* method parser_prod#AAbstractClasskind#visit_all for (self: AAbstractClasskind, Visitor) */
4420 void parser_prod__AAbstractClasskind__visit_all(val* self, val* p0) {
4421 val* var_v /* var v: Visitor */;
4422 val* var /* : TKwabstract */;
4423 val* var1 /* : TKwclass */;
4424 var_v = p0;
4425 var = self->attrs[COLOR_parser_nodes__AAbstractClasskind___n_kwabstract].val; /* _n_kwabstract on <self:AAbstractClasskind> */
4426 if (unlikely(var == NULL)) {
4427 PRINT_ERROR("Runtime error: %s", "Uninitialized attribute _n_kwabstract");
4428 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 622);
4429 show_backtrace(1);
4430 }
4431 {
4432 parser_nodes__Visitor__enter_visit(var_v, var); /* Direct call parser_nodes#Visitor#enter_visit on <var_v:Visitor>*/
4433 }
4434 var1 = self->attrs[COLOR_parser_nodes__AAbstractClasskind___n_kwclass].val; /* _n_kwclass on <self:AAbstractClasskind> */
4435 if (unlikely(var1 == NULL)) {
4436 PRINT_ERROR("Runtime error: %s", "Uninitialized attribute _n_kwclass");
4437 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 623);
4438 show_backtrace(1);
4439 }
4440 {
4441 parser_nodes__Visitor__enter_visit(var_v, var1); /* Direct call parser_nodes#Visitor#enter_visit on <var_v:Visitor>*/
4442 }
4443 RET_LABEL:;
4444 }
4445 /* method parser_prod#AAbstractClasskind#visit_all for (self: Object, Visitor) */
4446 void VIRTUAL_parser_prod__AAbstractClasskind__visit_all(val* self, val* p0) {
4447 parser_prod__AAbstractClasskind__visit_all(self, p0); /* Direct call parser_prod#AAbstractClasskind#visit_all on <self:Object(AAbstractClasskind)>*/
4448 RET_LABEL:;
4449 }
4450 /* method parser_prod#AInterfaceClasskind#init_ainterfaceclasskind for (self: AInterfaceClasskind, nullable TKwinterface) */
4451 void parser_prod__AInterfaceClasskind__init_ainterfaceclasskind(val* self, val* p0) {
4452 val* var_n_kwinterface /* var n_kwinterface: nullable TKwinterface */;
4453 var_n_kwinterface = p0;
4454 if (unlikely(var_n_kwinterface == NULL)) {
4455 PRINT_ERROR("Runtime error: %s", "Cast failed");
4456 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 631);
4457 show_backtrace(1);
4458 }
4459 self->attrs[COLOR_parser_nodes__AInterfaceClasskind___n_kwinterface].val = var_n_kwinterface; /* _n_kwinterface on <self:AInterfaceClasskind> */
4460 if (var_n_kwinterface == NULL) {
4461 PRINT_ERROR("Runtime error: %s", "Receiver is null");
4462 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 632);
4463 show_backtrace(1);
4464 } else {
4465 { /* Inline parser_nodes#ANode#parent= (var_n_kwinterface,self) on <var_n_kwinterface:nullable TKwinterface> */
4466 if (unlikely(var_n_kwinterface == NULL)) {
4467 PRINT_ERROR("Runtime error: %s", "Receiver is null");
4468 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_nodes.nit", 38);
4469 show_backtrace(1);
4470 }
4471 var_n_kwinterface->attrs[COLOR_parser_nodes__ANode___parent].val = self; /* _parent on <var_n_kwinterface:nullable TKwinterface> */
4472 RET_LABEL1:(void)0;
4473 }
4474 }
4475 RET_LABEL:;
4476 }
4477 /* method parser_prod#AInterfaceClasskind#init_ainterfaceclasskind for (self: Object, nullable TKwinterface) */
4478 void VIRTUAL_parser_prod__AInterfaceClasskind__init_ainterfaceclasskind(val* self, val* p0) {
4479 parser_prod__AInterfaceClasskind__init_ainterfaceclasskind(self, p0); /* Direct call parser_prod#AInterfaceClasskind#init_ainterfaceclasskind on <self:Object(AInterfaceClasskind)>*/
4480 RET_LABEL:;
4481 }
4482 /* method parser_prod#AInterfaceClasskind#replace_child for (self: AInterfaceClasskind, ANode, nullable ANode) */
4483 void parser_prod__AInterfaceClasskind__replace_child(val* self, val* p0, val* p1) {
4484 val* var_old_child /* var old_child: ANode */;
4485 val* var_new_child /* var new_child: nullable ANode */;
4486 val* var /* : TKwinterface */;
4487 short int var1 /* : Bool */;
4488 short int var2 /* : Bool */;
4489 val* var_other /* var other: nullable Object */;
4490 short int var4 /* : Bool */;
4491 short int var6 /* : Bool */;
4492 short int var7 /* : Bool */;
4493 int cltype;
4494 int idtype;
4495 const char* var_class_name;
4496 var_old_child = p0;
4497 var_new_child = p1;
4498 var = self->attrs[COLOR_parser_nodes__AInterfaceClasskind___n_kwinterface].val; /* _n_kwinterface on <self:AInterfaceClasskind> */
4499 if (unlikely(var == NULL)) {
4500 PRINT_ERROR("Runtime error: %s", "Uninitialized attribute _n_kwinterface");
4501 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 637);
4502 show_backtrace(1);
4503 }
4504 {
4505 { /* Inline kernel#Object#== (var,var_old_child) on <var:TKwinterface> */
4506 var_other = var_old_child;
4507 {
4508 { /* Inline kernel#Object#is_same_instance (var,var_other) on <var:TKwinterface> */
4509 var6 = var == var_other;
4510 var4 = var6;
4511 goto RET_LABEL5;
4512 RET_LABEL5:(void)0;
4513 }
4514 }
4515 var2 = var4;
4516 goto RET_LABEL3;
4517 RET_LABEL3:(void)0;
4518 }
4519 var1 = var2;
4520 }
4521 if (var1){
4522 /* <var_new_child:nullable ANode> isa TKwinterface */
4523 cltype = type_parser_nodes__TKwinterface.color;
4524 idtype = type_parser_nodes__TKwinterface.id;
4525 if(var_new_child == NULL) {
4526 var7 = 0;
4527 } else {
4528 if(cltype >= var_new_child->type->table_size) {
4529 var7 = 0;
4530 } else {
4531 var7 = var_new_child->type->type_table[cltype] == idtype;
4532 }
4533 }
4534 if (unlikely(!var7)) {
4535 var_class_name = var_new_child == NULL ? "null" : var_new_child->type->name;
4536 PRINT_ERROR("Runtime error: Cast failed. Expected `%s`, got `%s`", "TKwinterface", var_class_name);
4537 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 638);
4538 show_backtrace(1);
4539 }
4540 {
4541 parser_prod__AInterfaceClasskind__n_kwinterface_61d(self, var_new_child); /* Direct call parser_prod#AInterfaceClasskind#n_kwinterface= on <self:AInterfaceClasskind>*/
4542 }
4543 goto RET_LABEL;
4544 } else {
4545 }
4546 RET_LABEL:;
4547 }
4548 /* method parser_prod#AInterfaceClasskind#replace_child for (self: Object, ANode, nullable ANode) */
4549 void VIRTUAL_parser_prod__AInterfaceClasskind__replace_child(val* self, val* p0, val* p1) {
4550 parser_prod__AInterfaceClasskind__replace_child(self, p0, p1); /* Direct call parser_prod#AInterfaceClasskind#replace_child on <self:Object(AInterfaceClasskind)>*/
4551 RET_LABEL:;
4552 }
4553 /* method parser_prod#AInterfaceClasskind#n_kwinterface= for (self: AInterfaceClasskind, TKwinterface) */
4554 void parser_prod__AInterfaceClasskind__n_kwinterface_61d(val* self, val* p0) {
4555 val* var_node /* var node: TKwinterface */;
4556 var_node = p0;
4557 self->attrs[COLOR_parser_nodes__AInterfaceClasskind___n_kwinterface].val = var_node; /* _n_kwinterface on <self:AInterfaceClasskind> */
4558 {
4559 { /* Inline parser_nodes#ANode#parent= (var_node,self) on <var_node:TKwinterface> */
4560 var_node->attrs[COLOR_parser_nodes__ANode___parent].val = self; /* _parent on <var_node:TKwinterface> */
4561 RET_LABEL1:(void)0;
4562 }
4563 }
4564 RET_LABEL:;
4565 }
4566 /* method parser_prod#AInterfaceClasskind#n_kwinterface= for (self: Object, TKwinterface) */
4567 void VIRTUAL_parser_prod__AInterfaceClasskind__n_kwinterface_61d(val* self, val* p0) {
4568 parser_prod__AInterfaceClasskind__n_kwinterface_61d(self, p0); /* Direct call parser_prod#AInterfaceClasskind#n_kwinterface= on <self:Object(AInterfaceClasskind)>*/
4569 RET_LABEL:;
4570 }
4571 /* method parser_prod#AInterfaceClasskind#visit_all for (self: AInterfaceClasskind, Visitor) */
4572 void parser_prod__AInterfaceClasskind__visit_all(val* self, val* p0) {
4573 val* var_v /* var v: Visitor */;
4574 val* var /* : TKwinterface */;
4575 var_v = p0;
4576 var = self->attrs[COLOR_parser_nodes__AInterfaceClasskind___n_kwinterface].val; /* _n_kwinterface on <self:AInterfaceClasskind> */
4577 if (unlikely(var == NULL)) {
4578 PRINT_ERROR("Runtime error: %s", "Uninitialized attribute _n_kwinterface");
4579 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 652);
4580 show_backtrace(1);
4581 }
4582 {
4583 parser_nodes__Visitor__enter_visit(var_v, var); /* Direct call parser_nodes#Visitor#enter_visit on <var_v:Visitor>*/
4584 }
4585 RET_LABEL:;
4586 }
4587 /* method parser_prod#AInterfaceClasskind#visit_all for (self: Object, Visitor) */
4588 void VIRTUAL_parser_prod__AInterfaceClasskind__visit_all(val* self, val* p0) {
4589 parser_prod__AInterfaceClasskind__visit_all(self, p0); /* Direct call parser_prod#AInterfaceClasskind#visit_all on <self:Object(AInterfaceClasskind)>*/
4590 RET_LABEL:;
4591 }
4592 /* method parser_prod#AEnumClasskind#init_aenumclasskind for (self: AEnumClasskind, nullable TKwenum) */
4593 void parser_prod__AEnumClasskind__init_aenumclasskind(val* self, val* p0) {
4594 val* var_n_kwenum /* var n_kwenum: nullable TKwenum */;
4595 var_n_kwenum = p0;
4596 if (unlikely(var_n_kwenum == NULL)) {
4597 PRINT_ERROR("Runtime error: %s", "Cast failed");
4598 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 660);
4599 show_backtrace(1);
4600 }
4601 self->attrs[COLOR_parser_nodes__AEnumClasskind___n_kwenum].val = var_n_kwenum; /* _n_kwenum on <self:AEnumClasskind> */
4602 if (var_n_kwenum == NULL) {
4603 PRINT_ERROR("Runtime error: %s", "Receiver is null");
4604 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 661);
4605 show_backtrace(1);
4606 } else {
4607 { /* Inline parser_nodes#ANode#parent= (var_n_kwenum,self) on <var_n_kwenum:nullable TKwenum> */
4608 if (unlikely(var_n_kwenum == NULL)) {
4609 PRINT_ERROR("Runtime error: %s", "Receiver is null");
4610 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_nodes.nit", 38);
4611 show_backtrace(1);
4612 }
4613 var_n_kwenum->attrs[COLOR_parser_nodes__ANode___parent].val = self; /* _parent on <var_n_kwenum:nullable TKwenum> */
4614 RET_LABEL1:(void)0;
4615 }
4616 }
4617 RET_LABEL:;
4618 }
4619 /* method parser_prod#AEnumClasskind#init_aenumclasskind for (self: Object, nullable TKwenum) */
4620 void VIRTUAL_parser_prod__AEnumClasskind__init_aenumclasskind(val* self, val* p0) {
4621 parser_prod__AEnumClasskind__init_aenumclasskind(self, p0); /* Direct call parser_prod#AEnumClasskind#init_aenumclasskind on <self:Object(AEnumClasskind)>*/
4622 RET_LABEL:;
4623 }
4624 /* method parser_prod#AEnumClasskind#replace_child for (self: AEnumClasskind, ANode, nullable ANode) */
4625 void parser_prod__AEnumClasskind__replace_child(val* self, val* p0, val* p1) {
4626 val* var_old_child /* var old_child: ANode */;
4627 val* var_new_child /* var new_child: nullable ANode */;
4628 val* var /* : TKwenum */;
4629 short int var1 /* : Bool */;
4630 short int var2 /* : Bool */;
4631 val* var_other /* var other: nullable Object */;
4632 short int var4 /* : Bool */;
4633 short int var6 /* : Bool */;
4634 short int var7 /* : Bool */;
4635 int cltype;
4636 int idtype;
4637 const char* var_class_name;
4638 var_old_child = p0;
4639 var_new_child = p1;
4640 var = self->attrs[COLOR_parser_nodes__AEnumClasskind___n_kwenum].val; /* _n_kwenum on <self:AEnumClasskind> */
4641 if (unlikely(var == NULL)) {
4642 PRINT_ERROR("Runtime error: %s", "Uninitialized attribute _n_kwenum");
4643 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 666);
4644 show_backtrace(1);
4645 }
4646 {
4647 { /* Inline kernel#Object#== (var,var_old_child) on <var:TKwenum> */
4648 var_other = var_old_child;
4649 {
4650 { /* Inline kernel#Object#is_same_instance (var,var_other) on <var:TKwenum> */
4651 var6 = var == var_other;
4652 var4 = var6;
4653 goto RET_LABEL5;
4654 RET_LABEL5:(void)0;
4655 }
4656 }
4657 var2 = var4;
4658 goto RET_LABEL3;
4659 RET_LABEL3:(void)0;
4660 }
4661 var1 = var2;
4662 }
4663 if (var1){
4664 /* <var_new_child:nullable ANode> isa TKwenum */
4665 cltype = type_parser_nodes__TKwenum.color;
4666 idtype = type_parser_nodes__TKwenum.id;
4667 if(var_new_child == NULL) {
4668 var7 = 0;
4669 } else {
4670 if(cltype >= var_new_child->type->table_size) {
4671 var7 = 0;
4672 } else {
4673 var7 = var_new_child->type->type_table[cltype] == idtype;
4674 }
4675 }
4676 if (unlikely(!var7)) {
4677 var_class_name = var_new_child == NULL ? "null" : var_new_child->type->name;
4678 PRINT_ERROR("Runtime error: Cast failed. Expected `%s`, got `%s`", "TKwenum", var_class_name);
4679 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 667);
4680 show_backtrace(1);
4681 }
4682 {
4683 parser_prod__AEnumClasskind__n_kwenum_61d(self, var_new_child); /* Direct call parser_prod#AEnumClasskind#n_kwenum= on <self:AEnumClasskind>*/
4684 }
4685 goto RET_LABEL;
4686 } else {
4687 }
4688 RET_LABEL:;
4689 }
4690 /* method parser_prod#AEnumClasskind#replace_child for (self: Object, ANode, nullable ANode) */
4691 void VIRTUAL_parser_prod__AEnumClasskind__replace_child(val* self, val* p0, val* p1) {
4692 parser_prod__AEnumClasskind__replace_child(self, p0, p1); /* Direct call parser_prod#AEnumClasskind#replace_child on <self:Object(AEnumClasskind)>*/
4693 RET_LABEL:;
4694 }
4695 /* method parser_prod#AEnumClasskind#n_kwenum= for (self: AEnumClasskind, TKwenum) */
4696 void parser_prod__AEnumClasskind__n_kwenum_61d(val* self, val* p0) {
4697 val* var_node /* var node: TKwenum */;
4698 var_node = p0;
4699 self->attrs[COLOR_parser_nodes__AEnumClasskind___n_kwenum].val = var_node; /* _n_kwenum on <self:AEnumClasskind> */
4700 {
4701 { /* Inline parser_nodes#ANode#parent= (var_node,self) on <var_node:TKwenum> */
4702 var_node->attrs[COLOR_parser_nodes__ANode___parent].val = self; /* _parent on <var_node:TKwenum> */
4703 RET_LABEL1:(void)0;
4704 }
4705 }
4706 RET_LABEL:;
4707 }
4708 /* method parser_prod#AEnumClasskind#n_kwenum= for (self: Object, TKwenum) */
4709 void VIRTUAL_parser_prod__AEnumClasskind__n_kwenum_61d(val* self, val* p0) {
4710 parser_prod__AEnumClasskind__n_kwenum_61d(self, p0); /* Direct call parser_prod#AEnumClasskind#n_kwenum= on <self:Object(AEnumClasskind)>*/
4711 RET_LABEL:;
4712 }
4713 /* method parser_prod#AEnumClasskind#visit_all for (self: AEnumClasskind, Visitor) */
4714 void parser_prod__AEnumClasskind__visit_all(val* self, val* p0) {
4715 val* var_v /* var v: Visitor */;
4716 val* var /* : TKwenum */;
4717 var_v = p0;
4718 var = self->attrs[COLOR_parser_nodes__AEnumClasskind___n_kwenum].val; /* _n_kwenum on <self:AEnumClasskind> */
4719 if (unlikely(var == NULL)) {
4720 PRINT_ERROR("Runtime error: %s", "Uninitialized attribute _n_kwenum");
4721 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 681);
4722 show_backtrace(1);
4723 }
4724 {
4725 parser_nodes__Visitor__enter_visit(var_v, var); /* Direct call parser_nodes#Visitor#enter_visit on <var_v:Visitor>*/
4726 }
4727 RET_LABEL:;
4728 }
4729 /* method parser_prod#AEnumClasskind#visit_all for (self: Object, Visitor) */
4730 void VIRTUAL_parser_prod__AEnumClasskind__visit_all(val* self, val* p0) {
4731 parser_prod__AEnumClasskind__visit_all(self, p0); /* Direct call parser_prod#AEnumClasskind#visit_all on <self:Object(AEnumClasskind)>*/
4732 RET_LABEL:;
4733 }
4734 /* method parser_prod#AExternClasskind#init_aexternclasskind for (self: AExternClasskind, nullable TKwextern, nullable TKwclass) */
4735 void parser_prod__AExternClasskind__init_aexternclasskind(val* self, val* p0, val* p1) {
4736 val* var_n_kwextern /* var n_kwextern: nullable TKwextern */;
4737 val* var_n_kwclass /* var n_kwclass: nullable TKwclass */;
4738 val* var /* : null */;
4739 short int var2 /* : Bool */;
4740 short int var3 /* : Bool */;
4741 val* var_other /* var other: nullable Object */;
4742 short int var5 /* : Bool */;
4743 short int var6 /* : Bool */;
4744 short int var7 /* : Bool */;
4745 var_n_kwextern = p0;
4746 var_n_kwclass = p1;
4747 if (unlikely(var_n_kwextern == NULL)) {
4748 PRINT_ERROR("Runtime error: %s", "Cast failed");
4749 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 690);
4750 show_backtrace(1);
4751 }
4752 self->attrs[COLOR_parser_nodes__AExternClasskind___n_kwextern].val = var_n_kwextern; /* _n_kwextern on <self:AExternClasskind> */
4753 if (var_n_kwextern == NULL) {
4754 PRINT_ERROR("Runtime error: %s", "Receiver is null");
4755 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 691);
4756 show_backtrace(1);
4757 } else {
4758 { /* Inline parser_nodes#ANode#parent= (var_n_kwextern,self) on <var_n_kwextern:nullable TKwextern> */
4759 if (unlikely(var_n_kwextern == NULL)) {
4760 PRINT_ERROR("Runtime error: %s", "Receiver is null");
4761 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_nodes.nit", 38);
4762 show_backtrace(1);
4763 }
4764 var_n_kwextern->attrs[COLOR_parser_nodes__ANode___parent].val = self; /* _parent on <var_n_kwextern:nullable TKwextern> */
4765 RET_LABEL1:(void)0;
4766 }
4767 }
4768 self->attrs[COLOR_parser_nodes__AExternClasskind___n_kwclass].val = var_n_kwclass; /* _n_kwclass on <self:AExternClasskind> */
4769 var = NULL;
4770 if (var_n_kwclass == NULL) {
4771 var2 = 0; /* is null */
4772 } else {
4773 var2 = 1; /* arg is null and recv is not */
4774 }
4775 if (0) {
4776 { /* Inline kernel#Object#!= (var_n_kwclass,var) on <var_n_kwclass:nullable TKwclass> */
4777 var_other = var;
4778 {
4779 var6 = ((short int (*)(val*, val*))(var_n_kwclass->class->vft[COLOR_kernel__Object___61d_61d]))(var_n_kwclass, var_other) /* == on <var_n_kwclass:nullable TKwclass(TKwclass)>*/;
4780 var5 = var6;
4781 }
4782 var7 = !var5;
4783 var3 = var7;
4784 goto RET_LABEL4;
4785 RET_LABEL4:(void)0;
4786 }
4787 var2 = var3;
4788 }
4789 if (var2){
4790 {
4791 { /* Inline parser_nodes#ANode#parent= (var_n_kwclass,self) on <var_n_kwclass:nullable TKwclass(TKwclass)> */
4792 var_n_kwclass->attrs[COLOR_parser_nodes__ANode___parent].val = self; /* _parent on <var_n_kwclass:nullable TKwclass(TKwclass)> */
4793 RET_LABEL8:(void)0;
4794 }
4795 }
4796 } else {
4797 }
4798 RET_LABEL:;
4799 }
4800 /* method parser_prod#AExternClasskind#init_aexternclasskind for (self: Object, nullable TKwextern, nullable TKwclass) */
4801 void VIRTUAL_parser_prod__AExternClasskind__init_aexternclasskind(val* self, val* p0, val* p1) {
4802 parser_prod__AExternClasskind__init_aexternclasskind(self, p0, p1); /* Direct call parser_prod#AExternClasskind#init_aexternclasskind on <self:Object(AExternClasskind)>*/
4803 RET_LABEL:;
4804 }
4805 /* method parser_prod#AExternClasskind#replace_child for (self: AExternClasskind, ANode, nullable ANode) */
4806 void parser_prod__AExternClasskind__replace_child(val* self, val* p0, val* p1) {
4807 val* var_old_child /* var old_child: ANode */;
4808 val* var_new_child /* var new_child: nullable ANode */;
4809 val* var /* : TKwextern */;
4810 short int var1 /* : Bool */;
4811 short int var2 /* : Bool */;
4812 val* var_other /* var other: nullable Object */;
4813 short int var4 /* : Bool */;
4814 short int var6 /* : Bool */;
4815 short int var7 /* : Bool */;
4816 int cltype;
4817 int idtype;
4818 const char* var_class_name;
4819 val* var8 /* : nullable TKwclass */;
4820 short int var9 /* : Bool */;
4821 short int var10 /* : Bool */;
4822 short int var12 /* : Bool */;
4823 short int var14 /* : Bool */;
4824 short int var15 /* : Bool */;
4825 int cltype16;
4826 int idtype17;
4827 const char* var_class_name18;
4828 var_old_child = p0;
4829 var_new_child = p1;
4830 var = self->attrs[COLOR_parser_nodes__AExternClasskind___n_kwextern].val; /* _n_kwextern on <self:AExternClasskind> */
4831 if (unlikely(var == NULL)) {
4832 PRINT_ERROR("Runtime error: %s", "Uninitialized attribute _n_kwextern");
4833 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 698);
4834 show_backtrace(1);
4835 }
4836 {
4837 { /* Inline kernel#Object#== (var,var_old_child) on <var:TKwextern> */
4838 var_other = var_old_child;
4839 {
4840 { /* Inline kernel#Object#is_same_instance (var,var_other) on <var:TKwextern> */
4841 var6 = var == var_other;
4842 var4 = var6;
4843 goto RET_LABEL5;
4844 RET_LABEL5:(void)0;
4845 }
4846 }
4847 var2 = var4;
4848 goto RET_LABEL3;
4849 RET_LABEL3:(void)0;
4850 }
4851 var1 = var2;
4852 }
4853 if (var1){
4854 /* <var_new_child:nullable ANode> isa TKwextern */
4855 cltype = type_parser_nodes__TKwextern.color;
4856 idtype = type_parser_nodes__TKwextern.id;
4857 if(var_new_child == NULL) {
4858 var7 = 0;
4859 } else {
4860 if(cltype >= var_new_child->type->table_size) {
4861 var7 = 0;
4862 } else {
4863 var7 = var_new_child->type->type_table[cltype] == idtype;
4864 }
4865 }
4866 if (unlikely(!var7)) {
4867 var_class_name = var_new_child == NULL ? "null" : var_new_child->type->name;
4868 PRINT_ERROR("Runtime error: Cast failed. Expected `%s`, got `%s`", "TKwextern", var_class_name);
4869 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 699);
4870 show_backtrace(1);
4871 }
4872 {
4873 parser_prod__AExternClasskind__n_kwextern_61d(self, var_new_child); /* Direct call parser_prod#AExternClasskind#n_kwextern= on <self:AExternClasskind>*/
4874 }
4875 goto RET_LABEL;
4876 } else {
4877 }
4878 var8 = self->attrs[COLOR_parser_nodes__AExternClasskind___n_kwclass].val; /* _n_kwclass on <self:AExternClasskind> */
4879 if (var8 == NULL) {
4880 var9 = 0; /* <var_old_child:ANode> cannot be null */
4881 } else {
4882 { /* Inline kernel#Object#== (var8,var_old_child) on <var8:nullable TKwclass> */
4883 var_other = var_old_child;
4884 {
4885 { /* Inline kernel#Object#is_same_instance (var8,var_other) on <var8:nullable TKwclass(TKwclass)> */
4886 var14 = var8 == var_other;
4887 var12 = var14;
4888 goto RET_LABEL13;
4889 RET_LABEL13:(void)0;
4890 }
4891 }
4892 var10 = var12;
4893 goto RET_LABEL11;
4894 RET_LABEL11:(void)0;
4895 }
4896 var9 = var10;
4897 }
4898 if (var9){
4899 /* <var_new_child:nullable ANode> isa nullable TKwclass */
4900 cltype16 = type_nullable_parser_nodes__TKwclass.color;
4901 idtype17 = type_nullable_parser_nodes__TKwclass.id;
4902 if(var_new_child == NULL) {
4903 var15 = 1;
4904 } else {
4905 if(cltype16 >= var_new_child->type->table_size) {
4906 var15 = 0;
4907 } else {
4908 var15 = var_new_child->type->type_table[cltype16] == idtype17;
4909 }
4910 }
4911 if (unlikely(!var15)) {
4912 var_class_name18 = var_new_child == NULL ? "null" : var_new_child->type->name;
4913 PRINT_ERROR("Runtime error: Cast failed. Expected `%s`, got `%s`", "nullable TKwclass", var_class_name18);
4914 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 703);
4915 show_backtrace(1);
4916 }
4917 {
4918 parser_prod__AExternClasskind__n_kwclass_61d(self, var_new_child); /* Direct call parser_prod#AExternClasskind#n_kwclass= on <self:AExternClasskind>*/
4919 }
4920 goto RET_LABEL;
4921 } else {
4922 }
4923 RET_LABEL:;
4924 }
4925 /* method parser_prod#AExternClasskind#replace_child for (self: Object, ANode, nullable ANode) */
4926 void VIRTUAL_parser_prod__AExternClasskind__replace_child(val* self, val* p0, val* p1) {
4927 parser_prod__AExternClasskind__replace_child(self, p0, p1); /* Direct call parser_prod#AExternClasskind#replace_child on <self:Object(AExternClasskind)>*/
4928 RET_LABEL:;
4929 }
4930 /* method parser_prod#AExternClasskind#n_kwextern= for (self: AExternClasskind, TKwextern) */
4931 void parser_prod__AExternClasskind__n_kwextern_61d(val* self, val* p0) {
4932 val* var_node /* var node: TKwextern */;
4933 var_node = p0;
4934 self->attrs[COLOR_parser_nodes__AExternClasskind___n_kwextern].val = var_node; /* _n_kwextern on <self:AExternClasskind> */
4935 {
4936 { /* Inline parser_nodes#ANode#parent= (var_node,self) on <var_node:TKwextern> */
4937 var_node->attrs[COLOR_parser_nodes__ANode___parent].val = self; /* _parent on <var_node:TKwextern> */
4938 RET_LABEL1:(void)0;
4939 }
4940 }
4941 RET_LABEL:;
4942 }
4943 /* method parser_prod#AExternClasskind#n_kwextern= for (self: Object, TKwextern) */
4944 void VIRTUAL_parser_prod__AExternClasskind__n_kwextern_61d(val* self, val* p0) {
4945 parser_prod__AExternClasskind__n_kwextern_61d(self, p0); /* Direct call parser_prod#AExternClasskind#n_kwextern= on <self:Object(AExternClasskind)>*/
4946 RET_LABEL:;
4947 }
4948 /* method parser_prod#AExternClasskind#n_kwclass= for (self: AExternClasskind, nullable TKwclass) */
4949 void parser_prod__AExternClasskind__n_kwclass_61d(val* self, val* p0) {
4950 val* var_node /* var node: nullable TKwclass */;
4951 val* var /* : null */;
4952 short int var1 /* : Bool */;
4953 short int var2 /* : Bool */;
4954 val* var_other /* var other: nullable Object */;
4955 short int var4 /* : Bool */;
4956 short int var5 /* : Bool */;
4957 short int var6 /* : Bool */;
4958 var_node = p0;
4959 self->attrs[COLOR_parser_nodes__AExternClasskind___n_kwclass].val = var_node; /* _n_kwclass on <self:AExternClasskind> */
4960 var = NULL;
4961 if (var_node == NULL) {
4962 var1 = 0; /* is null */
4963 } else {
4964 var1 = 1; /* arg is null and recv is not */
4965 }
4966 if (0) {
4967 { /* Inline kernel#Object#!= (var_node,var) on <var_node:nullable TKwclass> */
4968 var_other = var;
4969 {
4970 var5 = ((short int (*)(val*, val*))(var_node->class->vft[COLOR_kernel__Object___61d_61d]))(var_node, var_other) /* == on <var_node:nullable TKwclass(TKwclass)>*/;
4971 var4 = var5;
4972 }
4973 var6 = !var4;
4974 var2 = var6;
4975 goto RET_LABEL3;
4976 RET_LABEL3:(void)0;
4977 }
4978 var1 = var2;
4979 }
4980 if (var1){
4981 {
4982 { /* Inline parser_nodes#ANode#parent= (var_node,self) on <var_node:nullable TKwclass(TKwclass)> */
4983 var_node->attrs[COLOR_parser_nodes__ANode___parent].val = self; /* _parent on <var_node:nullable TKwclass(TKwclass)> */
4984 RET_LABEL7:(void)0;
4985 }
4986 }
4987 } else {
4988 }
4989 RET_LABEL:;
4990 }
4991 /* method parser_prod#AExternClasskind#n_kwclass= for (self: Object, nullable TKwclass) */
4992 void VIRTUAL_parser_prod__AExternClasskind__n_kwclass_61d(val* self, val* p0) {
4993 parser_prod__AExternClasskind__n_kwclass_61d(self, p0); /* Direct call parser_prod#AExternClasskind#n_kwclass= on <self:Object(AExternClasskind)>*/
4994 RET_LABEL:;
4995 }
4996 /* method parser_prod#AExternClasskind#visit_all for (self: AExternClasskind, Visitor) */
4997 void parser_prod__AExternClasskind__visit_all(val* self, val* p0) {
4998 val* var_v /* var v: Visitor */;
4999 val* var /* : TKwextern */;
5000 val* var1 /* : nullable TKwclass */;
5001 var_v = p0;
5002 var = self->attrs[COLOR_parser_nodes__AExternClasskind___n_kwextern].val; /* _n_kwextern on <self:AExternClasskind> */
5003 if (unlikely(var == NULL)) {
5004 PRINT_ERROR("Runtime error: %s", "Uninitialized attribute _n_kwextern");
5005 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 722);
5006 show_backtrace(1);
5007 }
5008 {
5009 parser_nodes__Visitor__enter_visit(var_v, var); /* Direct call parser_nodes#Visitor#enter_visit on <var_v:Visitor>*/
5010 }
5011 var1 = self->attrs[COLOR_parser_nodes__AExternClasskind___n_kwclass].val; /* _n_kwclass on <self:AExternClasskind> */
5012 {
5013 parser_nodes__Visitor__enter_visit(var_v, var1); /* Direct call parser_nodes#Visitor#enter_visit on <var_v:Visitor>*/
5014 }
5015 RET_LABEL:;
5016 }
5017 /* method parser_prod#AExternClasskind#visit_all for (self: Object, Visitor) */
5018 void VIRTUAL_parser_prod__AExternClasskind__visit_all(val* self, val* p0) {
5019 parser_prod__AExternClasskind__visit_all(self, p0); /* Direct call parser_prod#AExternClasskind#visit_all on <self:Object(AExternClasskind)>*/
5020 RET_LABEL:;
5021 }
5022 /* method parser_prod#AFormaldef#init_aformaldef for (self: AFormaldef, nullable TClassid, nullable AType, nullable AAnnotations) */
5023 void parser_prod__AFormaldef__init_aformaldef(val* self, val* p0, val* p1, val* p2) {
5024 val* var_n_id /* var n_id: nullable TClassid */;
5025 val* var_n_type /* var n_type: nullable AType */;
5026 val* var_n_annotations /* var n_annotations: nullable AAnnotations */;
5027 val* var /* : null */;
5028 short int var2 /* : Bool */;
5029 short int var3 /* : Bool */;
5030 val* var_other /* var other: nullable Object */;
5031 short int var5 /* : Bool */;
5032 short int var6 /* : Bool */;
5033 short int var7 /* : Bool */;
5034 val* var9 /* : null */;
5035 short int var10 /* : Bool */;
5036 short int var11 /* : Bool */;
5037 short int var13 /* : Bool */;
5038 short int var14 /* : Bool */;
5039 short int var15 /* : Bool */;
5040 var_n_id = p0;
5041 var_n_type = p1;
5042 var_n_annotations = p2;
5043 if (unlikely(var_n_id == NULL)) {
5044 PRINT_ERROR("Runtime error: %s", "Cast failed");
5045 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 733);
5046 show_backtrace(1);
5047 }
5048 self->attrs[COLOR_parser_nodes__AFormaldef___n_id].val = var_n_id; /* _n_id on <self:AFormaldef> */
5049 if (var_n_id == NULL) {
5050 PRINT_ERROR("Runtime error: %s", "Receiver is null");
5051 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 734);
5052 show_backtrace(1);
5053 } else {
5054 { /* Inline parser_nodes#ANode#parent= (var_n_id,self) on <var_n_id:nullable TClassid> */
5055 if (unlikely(var_n_id == NULL)) {
5056 PRINT_ERROR("Runtime error: %s", "Receiver is null");
5057 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_nodes.nit", 38);
5058 show_backtrace(1);
5059 }
5060 var_n_id->attrs[COLOR_parser_nodes__ANode___parent].val = self; /* _parent on <var_n_id:nullable TClassid> */
5061 RET_LABEL1:(void)0;
5062 }
5063 }
5064 self->attrs[COLOR_parser_nodes__AFormaldef___n_type].val = var_n_type; /* _n_type on <self:AFormaldef> */
5065 var = NULL;
5066 if (var_n_type == NULL) {
5067 var2 = 0; /* is null */
5068 } else {
5069 var2 = 1; /* arg is null and recv is not */
5070 }
5071 if (0) {
5072 { /* Inline kernel#Object#!= (var_n_type,var) on <var_n_type:nullable AType> */
5073 var_other = var;
5074 {
5075 var6 = ((short int (*)(val*, val*))(var_n_type->class->vft[COLOR_kernel__Object___61d_61d]))(var_n_type, var_other) /* == on <var_n_type:nullable AType(AType)>*/;
5076 var5 = var6;
5077 }
5078 var7 = !var5;
5079 var3 = var7;
5080 goto RET_LABEL4;
5081 RET_LABEL4:(void)0;
5082 }
5083 var2 = var3;
5084 }
5085 if (var2){
5086 {
5087 { /* Inline parser_nodes#ANode#parent= (var_n_type,self) on <var_n_type:nullable AType(AType)> */
5088 var_n_type->attrs[COLOR_parser_nodes__ANode___parent].val = self; /* _parent on <var_n_type:nullable AType(AType)> */
5089 RET_LABEL8:(void)0;
5090 }
5091 }
5092 } else {
5093 }
5094 self->attrs[COLOR_parser_nodes__Prod___n_annotations].val = var_n_annotations; /* _n_annotations on <self:AFormaldef> */
5095 var9 = NULL;
5096 if (var_n_annotations == NULL) {
5097 var10 = 0; /* is null */
5098 } else {
5099 var10 = 1; /* arg is null and recv is not */
5100 }
5101 if (0) {
5102 { /* Inline kernel#Object#!= (var_n_annotations,var9) on <var_n_annotations:nullable AAnnotations> */
5103 var_other = var9;
5104 {
5105 var14 = ((short int (*)(val*, val*))(var_n_annotations->class->vft[COLOR_kernel__Object___61d_61d]))(var_n_annotations, var_other) /* == on <var_n_annotations:nullable AAnnotations(AAnnotations)>*/;
5106 var13 = var14;
5107 }
5108 var15 = !var13;
5109 var11 = var15;
5110 goto RET_LABEL12;
5111 RET_LABEL12:(void)0;
5112 }
5113 var10 = var11;
5114 }
5115 if (var10){
5116 {
5117 { /* Inline parser_nodes#ANode#parent= (var_n_annotations,self) on <var_n_annotations:nullable AAnnotations(AAnnotations)> */
5118 var_n_annotations->attrs[COLOR_parser_nodes__ANode___parent].val = self; /* _parent on <var_n_annotations:nullable AAnnotations(AAnnotations)> */
5119 RET_LABEL16:(void)0;
5120 }
5121 }
5122 } else {
5123 }
5124 RET_LABEL:;
5125 }
5126 /* method parser_prod#AFormaldef#init_aformaldef for (self: Object, nullable TClassid, nullable AType, nullable AAnnotations) */
5127 void VIRTUAL_parser_prod__AFormaldef__init_aformaldef(val* self, val* p0, val* p1, val* p2) {
5128 parser_prod__AFormaldef__init_aformaldef(self, p0, p1, p2); /* Direct call parser_prod#AFormaldef#init_aformaldef on <self:Object(AFormaldef)>*/
5129 RET_LABEL:;
5130 }
5131 /* method parser_prod#AFormaldef#replace_child for (self: AFormaldef, ANode, nullable ANode) */
5132 void parser_prod__AFormaldef__replace_child(val* self, val* p0, val* p1) {
5133 val* var_old_child /* var old_child: ANode */;
5134 val* var_new_child /* var new_child: nullable ANode */;
5135 val* var /* : TClassid */;
5136 short int var1 /* : Bool */;
5137 short int var2 /* : Bool */;
5138 val* var_other /* var other: nullable Object */;
5139 short int var4 /* : Bool */;
5140 short int var6 /* : Bool */;
5141 short int var7 /* : Bool */;
5142 int cltype;
5143 int idtype;
5144 const char* var_class_name;
5145 val* var8 /* : nullable AType */;
5146 short int var9 /* : Bool */;
5147 short int var10 /* : Bool */;
5148 short int var12 /* : Bool */;
5149 short int var14 /* : Bool */;
5150 short int var15 /* : Bool */;
5151 int cltype16;
5152 int idtype17;
5153 const char* var_class_name18;
5154 val* var19 /* : nullable AAnnotations */;
5155 short int var20 /* : Bool */;
5156 short int var21 /* : Bool */;
5157 short int var23 /* : Bool */;
5158 short int var25 /* : Bool */;
5159 short int var26 /* : Bool */;
5160 int cltype27;
5161 int idtype28;
5162 const char* var_class_name29;
5163 var_old_child = p0;
5164 var_new_child = p1;
5165 var = self->attrs[COLOR_parser_nodes__AFormaldef___n_id].val; /* _n_id on <self:AFormaldef> */
5166 if (unlikely(var == NULL)) {
5167 PRINT_ERROR("Runtime error: %s", "Uninitialized attribute _n_id");
5168 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 743);
5169 show_backtrace(1);
5170 }
5171 {
5172 { /* Inline kernel#Object#== (var,var_old_child) on <var:TClassid> */
5173 var_other = var_old_child;
5174 {
5175 { /* Inline kernel#Object#is_same_instance (var,var_other) on <var:TClassid> */
5176 var6 = var == var_other;
5177 var4 = var6;
5178 goto RET_LABEL5;
5179 RET_LABEL5:(void)0;
5180 }
5181 }
5182 var2 = var4;
5183 goto RET_LABEL3;
5184 RET_LABEL3:(void)0;
5185 }
5186 var1 = var2;
5187 }
5188 if (var1){
5189 /* <var_new_child:nullable ANode> isa TClassid */
5190 cltype = type_parser_nodes__TClassid.color;
5191 idtype = type_parser_nodes__TClassid.id;
5192 if(var_new_child == NULL) {
5193 var7 = 0;
5194 } else {
5195 if(cltype >= var_new_child->type->table_size) {
5196 var7 = 0;
5197 } else {
5198 var7 = var_new_child->type->type_table[cltype] == idtype;
5199 }
5200 }
5201 if (unlikely(!var7)) {
5202 var_class_name = var_new_child == NULL ? "null" : var_new_child->type->name;
5203 PRINT_ERROR("Runtime error: Cast failed. Expected `%s`, got `%s`", "TClassid", var_class_name);
5204 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 744);
5205 show_backtrace(1);
5206 }
5207 {
5208 parser_prod__AFormaldef__n_id_61d(self, var_new_child); /* Direct call parser_prod#AFormaldef#n_id= on <self:AFormaldef>*/
5209 }
5210 goto RET_LABEL;
5211 } else {
5212 }
5213 var8 = self->attrs[COLOR_parser_nodes__AFormaldef___n_type].val; /* _n_type on <self:AFormaldef> */
5214 if (var8 == NULL) {
5215 var9 = 0; /* <var_old_child:ANode> cannot be null */
5216 } else {
5217 { /* Inline kernel#Object#== (var8,var_old_child) on <var8:nullable AType> */
5218 var_other = var_old_child;
5219 {
5220 { /* Inline kernel#Object#is_same_instance (var8,var_other) on <var8:nullable AType(AType)> */
5221 var14 = var8 == var_other;
5222 var12 = var14;
5223 goto RET_LABEL13;
5224 RET_LABEL13:(void)0;
5225 }
5226 }
5227 var10 = var12;
5228 goto RET_LABEL11;
5229 RET_LABEL11:(void)0;
5230 }
5231 var9 = var10;
5232 }
5233 if (var9){
5234 /* <var_new_child:nullable ANode> isa nullable AType */
5235 cltype16 = type_nullable_parser_nodes__AType.color;
5236 idtype17 = type_nullable_parser_nodes__AType.id;
5237 if(var_new_child == NULL) {
5238 var15 = 1;
5239 } else {
5240 if(cltype16 >= var_new_child->type->table_size) {
5241 var15 = 0;
5242 } else {
5243 var15 = var_new_child->type->type_table[cltype16] == idtype17;
5244 }
5245 }
5246 if (unlikely(!var15)) {
5247 var_class_name18 = var_new_child == NULL ? "null" : var_new_child->type->name;
5248 PRINT_ERROR("Runtime error: Cast failed. Expected `%s`, got `%s`", "nullable AType", var_class_name18);
5249 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 748);
5250 show_backtrace(1);
5251 }
5252 {
5253 parser_prod__AFormaldef__n_type_61d(self, var_new_child); /* Direct call parser_prod#AFormaldef#n_type= on <self:AFormaldef>*/
5254 }
5255 goto RET_LABEL;
5256 } else {
5257 }
5258 var19 = self->attrs[COLOR_parser_nodes__Prod___n_annotations].val; /* _n_annotations on <self:AFormaldef> */
5259 if (var19 == NULL) {
5260 var20 = 0; /* <var_old_child:ANode> cannot be null */
5261 } else {
5262 { /* Inline kernel#Object#== (var19,var_old_child) on <var19:nullable AAnnotations> */
5263 var_other = var_old_child;
5264 {
5265 { /* Inline kernel#Object#is_same_instance (var19,var_other) on <var19:nullable AAnnotations(AAnnotations)> */
5266 var25 = var19 == var_other;
5267 var23 = var25;
5268 goto RET_LABEL24;
5269 RET_LABEL24:(void)0;
5270 }
5271 }
5272 var21 = var23;
5273 goto RET_LABEL22;
5274 RET_LABEL22:(void)0;
5275 }
5276 var20 = var21;
5277 }
5278 if (var20){
5279 /* <var_new_child:nullable ANode> isa nullable AAnnotations */
5280 cltype27 = type_nullable_parser_nodes__AAnnotations.color;
5281 idtype28 = type_nullable_parser_nodes__AAnnotations.id;
5282 if(var_new_child == NULL) {
5283 var26 = 1;
5284 } else {
5285 if(cltype27 >= var_new_child->type->table_size) {
5286 var26 = 0;
5287 } else {
5288 var26 = var_new_child->type->type_table[cltype27] == idtype28;
5289 }
5290 }
5291 if (unlikely(!var26)) {
5292 var_class_name29 = var_new_child == NULL ? "null" : var_new_child->type->name;
5293 PRINT_ERROR("Runtime error: Cast failed. Expected `%s`, got `%s`", "nullable AAnnotations", var_class_name29);
5294 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 752);
5295 show_backtrace(1);
5296 }
5297 {
5298 parser_prod__AFormaldef__n_annotations_61d(self, var_new_child); /* Direct call parser_prod#AFormaldef#n_annotations= on <self:AFormaldef>*/
5299 }
5300 goto RET_LABEL;
5301 } else {
5302 }
5303 RET_LABEL:;
5304 }
5305 /* method parser_prod#AFormaldef#replace_child for (self: Object, ANode, nullable ANode) */
5306 void VIRTUAL_parser_prod__AFormaldef__replace_child(val* self, val* p0, val* p1) {
5307 parser_prod__AFormaldef__replace_child(self, p0, p1); /* Direct call parser_prod#AFormaldef#replace_child on <self:Object(AFormaldef)>*/
5308 RET_LABEL:;
5309 }
5310 /* method parser_prod#AFormaldef#n_id= for (self: AFormaldef, TClassid) */
5311 void parser_prod__AFormaldef__n_id_61d(val* self, val* p0) {
5312 val* var_node /* var node: TClassid */;
5313 var_node = p0;
5314 self->attrs[COLOR_parser_nodes__AFormaldef___n_id].val = var_node; /* _n_id on <self:AFormaldef> */
5315 {
5316 { /* Inline parser_nodes#ANode#parent= (var_node,self) on <var_node:TClassid> */
5317 var_node->attrs[COLOR_parser_nodes__ANode___parent].val = self; /* _parent on <var_node:TClassid> */
5318 RET_LABEL1:(void)0;
5319 }
5320 }
5321 RET_LABEL:;
5322 }
5323 /* method parser_prod#AFormaldef#n_id= for (self: Object, TClassid) */
5324 void VIRTUAL_parser_prod__AFormaldef__n_id_61d(val* self, val* p0) {
5325 parser_prod__AFormaldef__n_id_61d(self, p0); /* Direct call parser_prod#AFormaldef#n_id= on <self:Object(AFormaldef)>*/
5326 RET_LABEL:;
5327 }
5328 /* method parser_prod#AFormaldef#n_type= for (self: AFormaldef, nullable AType) */
5329 void parser_prod__AFormaldef__n_type_61d(val* self, val* p0) {
5330 val* var_node /* var node: nullable AType */;
5331 val* var /* : null */;
5332 short int var1 /* : Bool */;
5333 short int var2 /* : Bool */;
5334 val* var_other /* var other: nullable Object */;
5335 short int var4 /* : Bool */;
5336 short int var5 /* : Bool */;
5337 short int var6 /* : Bool */;
5338 var_node = p0;
5339 self->attrs[COLOR_parser_nodes__AFormaldef___n_type].val = var_node; /* _n_type on <self:AFormaldef> */
5340 var = NULL;
5341 if (var_node == NULL) {
5342 var1 = 0; /* is null */
5343 } else {
5344 var1 = 1; /* arg is null and recv is not */
5345 }
5346 if (0) {
5347 { /* Inline kernel#Object#!= (var_node,var) on <var_node:nullable AType> */
5348 var_other = var;
5349 {
5350 var5 = ((short int (*)(val*, val*))(var_node->class->vft[COLOR_kernel__Object___61d_61d]))(var_node, var_other) /* == on <var_node:nullable AType(AType)>*/;
5351 var4 = var5;
5352 }
5353 var6 = !var4;
5354 var2 = var6;
5355 goto RET_LABEL3;
5356 RET_LABEL3:(void)0;
5357 }
5358 var1 = var2;
5359 }
5360 if (var1){
5361 {
5362 { /* Inline parser_nodes#ANode#parent= (var_node,self) on <var_node:nullable AType(AType)> */
5363 var_node->attrs[COLOR_parser_nodes__ANode___parent].val = self; /* _parent on <var_node:nullable AType(AType)> */
5364 RET_LABEL7:(void)0;
5365 }
5366 }
5367 } else {
5368 }
5369 RET_LABEL:;
5370 }
5371 /* method parser_prod#AFormaldef#n_type= for (self: Object, nullable AType) */
5372 void VIRTUAL_parser_prod__AFormaldef__n_type_61d(val* self, val* p0) {
5373 parser_prod__AFormaldef__n_type_61d(self, p0); /* Direct call parser_prod#AFormaldef#n_type= on <self:Object(AFormaldef)>*/
5374 RET_LABEL:;
5375 }
5376 /* method parser_prod#AFormaldef#n_annotations= for (self: AFormaldef, nullable AAnnotations) */
5377 void parser_prod__AFormaldef__n_annotations_61d(val* self, val* p0) {
5378 val* var_node /* var node: nullable AAnnotations */;
5379 val* var /* : null */;
5380 short int var1 /* : Bool */;
5381 short int var2 /* : Bool */;
5382 val* var_other /* var other: nullable Object */;
5383 short int var4 /* : Bool */;
5384 short int var5 /* : Bool */;
5385 short int var6 /* : Bool */;
5386 var_node = p0;
5387 self->attrs[COLOR_parser_nodes__Prod___n_annotations].val = var_node; /* _n_annotations on <self:AFormaldef> */
5388 var = NULL;
5389 if (var_node == NULL) {
5390 var1 = 0; /* is null */
5391 } else {
5392 var1 = 1; /* arg is null and recv is not */
5393 }
5394 if (0) {
5395 { /* Inline kernel#Object#!= (var_node,var) on <var_node:nullable AAnnotations> */
5396 var_other = var;
5397 {
5398 var5 = ((short int (*)(val*, val*))(var_node->class->vft[COLOR_kernel__Object___61d_61d]))(var_node, var_other) /* == on <var_node:nullable AAnnotations(AAnnotations)>*/;
5399 var4 = var5;
5400 }
5401 var6 = !var4;
5402 var2 = var6;
5403 goto RET_LABEL3;
5404 RET_LABEL3:(void)0;
5405 }
5406 var1 = var2;
5407 }
5408 if (var1){
5409 {
5410 { /* Inline parser_nodes#ANode#parent= (var_node,self) on <var_node:nullable AAnnotations(AAnnotations)> */
5411 var_node->attrs[COLOR_parser_nodes__ANode___parent].val = self; /* _parent on <var_node:nullable AAnnotations(AAnnotations)> */
5412 RET_LABEL7:(void)0;
5413 }
5414 }
5415 } else {
5416 }
5417 RET_LABEL:;
5418 }
5419 /* method parser_prod#AFormaldef#n_annotations= for (self: Object, nullable AAnnotations) */
5420 void VIRTUAL_parser_prod__AFormaldef__n_annotations_61d(val* self, val* p0) {
5421 parser_prod__AFormaldef__n_annotations_61d(self, p0); /* Direct call parser_prod#AFormaldef#n_annotations= on <self:Object(AFormaldef)>*/
5422 RET_LABEL:;
5423 }
5424 /* method parser_prod#AFormaldef#visit_all for (self: AFormaldef, Visitor) */
5425 void parser_prod__AFormaldef__visit_all(val* self, val* p0) {
5426 val* var_v /* var v: Visitor */;
5427 val* var /* : TClassid */;
5428 val* var1 /* : nullable AType */;
5429 val* var2 /* : nullable AAnnotations */;
5430 var_v = p0;
5431 var = self->attrs[COLOR_parser_nodes__AFormaldef___n_id].val; /* _n_id on <self:AFormaldef> */
5432 if (unlikely(var == NULL)) {
5433 PRINT_ERROR("Runtime error: %s", "Uninitialized attribute _n_id");
5434 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 776);
5435 show_backtrace(1);
5436 }
5437 {
5438 parser_nodes__Visitor__enter_visit(var_v, var); /* Direct call parser_nodes#Visitor#enter_visit on <var_v:Visitor>*/
5439 }
5440 var1 = self->attrs[COLOR_parser_nodes__AFormaldef___n_type].val; /* _n_type on <self:AFormaldef> */
5441 {
5442 parser_nodes__Visitor__enter_visit(var_v, var1); /* Direct call parser_nodes#Visitor#enter_visit on <var_v:Visitor>*/
5443 }
5444 var2 = self->attrs[COLOR_parser_nodes__Prod___n_annotations].val; /* _n_annotations on <self:AFormaldef> */
5445 {
5446 parser_nodes__Visitor__enter_visit(var_v, var2); /* Direct call parser_nodes#Visitor#enter_visit on <var_v:Visitor>*/
5447 }
5448 RET_LABEL:;
5449 }
5450 /* method parser_prod#AFormaldef#visit_all for (self: Object, Visitor) */
5451 void VIRTUAL_parser_prod__AFormaldef__visit_all(val* self, val* p0) {
5452 parser_prod__AFormaldef__visit_all(self, p0); /* Direct call parser_prod#AFormaldef#visit_all on <self:Object(AFormaldef)>*/
5453 RET_LABEL:;
5454 }
5455 /* method parser_prod#ASuperclass#init_asuperclass for (self: ASuperclass, nullable TKwsuper, nullable AType, nullable AAnnotations) */
5456 void parser_prod__ASuperclass__init_asuperclass(val* self, val* p0, val* p1, val* p2) {
5457 val* var_n_kwsuper /* var n_kwsuper: nullable TKwsuper */;
5458 val* var_n_type /* var n_type: nullable AType */;
5459 val* var_n_annotations /* var n_annotations: nullable AAnnotations */;
5460 val* var /* : null */;
5461 short int var3 /* : Bool */;
5462 short int var4 /* : Bool */;
5463 val* var_other /* var other: nullable Object */;
5464 short int var6 /* : Bool */;
5465 short int var7 /* : Bool */;
5466 short int var8 /* : Bool */;
5467 var_n_kwsuper = p0;
5468 var_n_type = p1;
5469 var_n_annotations = p2;
5470 if (unlikely(var_n_kwsuper == NULL)) {
5471 PRINT_ERROR("Runtime error: %s", "Cast failed");
5472 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 788);
5473 show_backtrace(1);
5474 }
5475 self->attrs[COLOR_parser_nodes__ASuperclass___n_kwsuper].val = var_n_kwsuper; /* _n_kwsuper on <self:ASuperclass> */
5476 if (var_n_kwsuper == NULL) {
5477 PRINT_ERROR("Runtime error: %s", "Receiver is null");
5478 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 789);
5479 show_backtrace(1);
5480 } else {
5481 { /* Inline parser_nodes#ANode#parent= (var_n_kwsuper,self) on <var_n_kwsuper:nullable TKwsuper> */
5482 if (unlikely(var_n_kwsuper == NULL)) {
5483 PRINT_ERROR("Runtime error: %s", "Receiver is null");
5484 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_nodes.nit", 38);
5485 show_backtrace(1);
5486 }
5487 var_n_kwsuper->attrs[COLOR_parser_nodes__ANode___parent].val = self; /* _parent on <var_n_kwsuper:nullable TKwsuper> */
5488 RET_LABEL1:(void)0;
5489 }
5490 }
5491 if (unlikely(var_n_type == NULL)) {
5492 PRINT_ERROR("Runtime error: %s", "Cast failed");
5493 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 790);
5494 show_backtrace(1);
5495 }
5496 self->attrs[COLOR_parser_nodes__ASuperclass___n_type].val = var_n_type; /* _n_type on <self:ASuperclass> */
5497 if (var_n_type == NULL) {
5498 PRINT_ERROR("Runtime error: %s", "Receiver is null");
5499 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 791);
5500 show_backtrace(1);
5501 } else {
5502 { /* Inline parser_nodes#ANode#parent= (var_n_type,self) on <var_n_type:nullable AType> */
5503 if (unlikely(var_n_type == NULL)) {
5504 PRINT_ERROR("Runtime error: %s", "Receiver is null");
5505 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_nodes.nit", 38);
5506 show_backtrace(1);
5507 }
5508 var_n_type->attrs[COLOR_parser_nodes__ANode___parent].val = self; /* _parent on <var_n_type:nullable AType> */
5509 RET_LABEL2:(void)0;
5510 }
5511 }
5512 self->attrs[COLOR_parser_nodes__Prod___n_annotations].val = var_n_annotations; /* _n_annotations on <self:ASuperclass> */
5513 var = NULL;
5514 if (var_n_annotations == NULL) {
5515 var3 = 0; /* is null */
5516 } else {
5517 var3 = 1; /* arg is null and recv is not */
5518 }
5519 if (0) {
5520 { /* Inline kernel#Object#!= (var_n_annotations,var) on <var_n_annotations:nullable AAnnotations> */
5521 var_other = var;
5522 {
5523 var7 = ((short int (*)(val*, val*))(var_n_annotations->class->vft[COLOR_kernel__Object___61d_61d]))(var_n_annotations, var_other) /* == on <var_n_annotations:nullable AAnnotations(AAnnotations)>*/;
5524 var6 = var7;
5525 }
5526 var8 = !var6;
5527 var4 = var8;
5528 goto RET_LABEL5;
5529 RET_LABEL5:(void)0;
5530 }
5531 var3 = var4;
5532 }
5533 if (var3){
5534 {
5535 { /* Inline parser_nodes#ANode#parent= (var_n_annotations,self) on <var_n_annotations:nullable AAnnotations(AAnnotations)> */
5536 var_n_annotations->attrs[COLOR_parser_nodes__ANode___parent].val = self; /* _parent on <var_n_annotations:nullable AAnnotations(AAnnotations)> */
5537 RET_LABEL9:(void)0;
5538 }
5539 }
5540 } else {
5541 }
5542 RET_LABEL:;
5543 }
5544 /* method parser_prod#ASuperclass#init_asuperclass for (self: Object, nullable TKwsuper, nullable AType, nullable AAnnotations) */
5545 void VIRTUAL_parser_prod__ASuperclass__init_asuperclass(val* self, val* p0, val* p1, val* p2) {
5546 parser_prod__ASuperclass__init_asuperclass(self, p0, p1, p2); /* Direct call parser_prod#ASuperclass#init_asuperclass on <self:Object(ASuperclass)>*/
5547 RET_LABEL:;
5548 }
5549 /* method parser_prod#ASuperclass#replace_child for (self: ASuperclass, ANode, nullable ANode) */
5550 void parser_prod__ASuperclass__replace_child(val* self, val* p0, val* p1) {
5551 val* var_old_child /* var old_child: ANode */;
5552 val* var_new_child /* var new_child: nullable ANode */;
5553 val* var /* : TKwsuper */;
5554 short int var1 /* : Bool */;
5555 short int var2 /* : Bool */;
5556 val* var_other /* var other: nullable Object */;
5557 short int var4 /* : Bool */;
5558 short int var6 /* : Bool */;
5559 short int var7 /* : Bool */;
5560 int cltype;
5561 int idtype;
5562 const char* var_class_name;
5563 val* var8 /* : AType */;
5564 short int var9 /* : Bool */;
5565 short int var10 /* : Bool */;
5566 short int var12 /* : Bool */;
5567 short int var14 /* : Bool */;
5568 short int var15 /* : Bool */;
5569 int cltype16;
5570 int idtype17;
5571 const char* var_class_name18;
5572 val* var19 /* : nullable AAnnotations */;
5573 short int var20 /* : Bool */;
5574 short int var21 /* : Bool */;
5575 short int var23 /* : Bool */;
5576 short int var25 /* : Bool */;
5577 short int var26 /* : Bool */;
5578 int cltype27;
5579 int idtype28;
5580 const char* var_class_name29;
5581 var_old_child = p0;
5582 var_new_child = p1;
5583 var = self->attrs[COLOR_parser_nodes__ASuperclass___n_kwsuper].val; /* _n_kwsuper on <self:ASuperclass> */
5584 if (unlikely(var == NULL)) {
5585 PRINT_ERROR("Runtime error: %s", "Uninitialized attribute _n_kwsuper");
5586 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 798);
5587 show_backtrace(1);
5588 }
5589 {
5590 { /* Inline kernel#Object#== (var,var_old_child) on <var:TKwsuper> */
5591 var_other = var_old_child;
5592 {
5593 { /* Inline kernel#Object#is_same_instance (var,var_other) on <var:TKwsuper> */
5594 var6 = var == var_other;
5595 var4 = var6;
5596 goto RET_LABEL5;
5597 RET_LABEL5:(void)0;
5598 }
5599 }
5600 var2 = var4;
5601 goto RET_LABEL3;
5602 RET_LABEL3:(void)0;
5603 }
5604 var1 = var2;
5605 }
5606 if (var1){
5607 /* <var_new_child:nullable ANode> isa TKwsuper */
5608 cltype = type_parser_nodes__TKwsuper.color;
5609 idtype = type_parser_nodes__TKwsuper.id;
5610 if(var_new_child == NULL) {
5611 var7 = 0;
5612 } else {
5613 if(cltype >= var_new_child->type->table_size) {
5614 var7 = 0;
5615 } else {
5616 var7 = var_new_child->type->type_table[cltype] == idtype;
5617 }
5618 }
5619 if (unlikely(!var7)) {
5620 var_class_name = var_new_child == NULL ? "null" : var_new_child->type->name;
5621 PRINT_ERROR("Runtime error: Cast failed. Expected `%s`, got `%s`", "TKwsuper", var_class_name);
5622 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 799);
5623 show_backtrace(1);
5624 }
5625 {
5626 parser_prod__ASuperclass__n_kwsuper_61d(self, var_new_child); /* Direct call parser_prod#ASuperclass#n_kwsuper= on <self:ASuperclass>*/
5627 }
5628 goto RET_LABEL;
5629 } else {
5630 }
5631 var8 = self->attrs[COLOR_parser_nodes__ASuperclass___n_type].val; /* _n_type on <self:ASuperclass> */
5632 if (unlikely(var8 == NULL)) {
5633 PRINT_ERROR("Runtime error: %s", "Uninitialized attribute _n_type");
5634 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 802);
5635 show_backtrace(1);
5636 }
5637 {
5638 { /* Inline kernel#Object#== (var8,var_old_child) on <var8:AType> */
5639 var_other = var_old_child;
5640 {
5641 { /* Inline kernel#Object#is_same_instance (var8,var_other) on <var8:AType> */
5642 var14 = var8 == var_other;
5643 var12 = var14;
5644 goto RET_LABEL13;
5645 RET_LABEL13:(void)0;
5646 }
5647 }
5648 var10 = var12;
5649 goto RET_LABEL11;
5650 RET_LABEL11:(void)0;
5651 }
5652 var9 = var10;
5653 }
5654 if (var9){
5655 /* <var_new_child:nullable ANode> isa AType */
5656 cltype16 = type_parser_nodes__AType.color;
5657 idtype17 = type_parser_nodes__AType.id;
5658 if(var_new_child == NULL) {
5659 var15 = 0;
5660 } else {
5661 if(cltype16 >= var_new_child->type->table_size) {
5662 var15 = 0;
5663 } else {
5664 var15 = var_new_child->type->type_table[cltype16] == idtype17;
5665 }
5666 }
5667 if (unlikely(!var15)) {
5668 var_class_name18 = var_new_child == NULL ? "null" : var_new_child->type->name;
5669 PRINT_ERROR("Runtime error: Cast failed. Expected `%s`, got `%s`", "AType", var_class_name18);
5670 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 803);
5671 show_backtrace(1);
5672 }
5673 {
5674 parser_prod__ASuperclass__n_type_61d(self, var_new_child); /* Direct call parser_prod#ASuperclass#n_type= on <self:ASuperclass>*/
5675 }
5676 goto RET_LABEL;
5677 } else {
5678 }
5679 var19 = self->attrs[COLOR_parser_nodes__Prod___n_annotations].val; /* _n_annotations on <self:ASuperclass> */
5680 if (var19 == NULL) {
5681 var20 = 0; /* <var_old_child:ANode> cannot be null */
5682 } else {
5683 { /* Inline kernel#Object#== (var19,var_old_child) on <var19:nullable AAnnotations> */
5684 var_other = var_old_child;
5685 {
5686 { /* Inline kernel#Object#is_same_instance (var19,var_other) on <var19:nullable AAnnotations(AAnnotations)> */
5687 var25 = var19 == var_other;
5688 var23 = var25;
5689 goto RET_LABEL24;
5690 RET_LABEL24:(void)0;
5691 }
5692 }
5693 var21 = var23;
5694 goto RET_LABEL22;
5695 RET_LABEL22:(void)0;
5696 }
5697 var20 = var21;
5698 }
5699 if (var20){
5700 /* <var_new_child:nullable ANode> isa nullable AAnnotations */
5701 cltype27 = type_nullable_parser_nodes__AAnnotations.color;
5702 idtype28 = type_nullable_parser_nodes__AAnnotations.id;
5703 if(var_new_child == NULL) {
5704 var26 = 1;
5705 } else {
5706 if(cltype27 >= var_new_child->type->table_size) {
5707 var26 = 0;
5708 } else {
5709 var26 = var_new_child->type->type_table[cltype27] == idtype28;
5710 }
5711 }
5712 if (unlikely(!var26)) {
5713 var_class_name29 = var_new_child == NULL ? "null" : var_new_child->type->name;
5714 PRINT_ERROR("Runtime error: Cast failed. Expected `%s`, got `%s`", "nullable AAnnotations", var_class_name29);
5715 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 807);
5716 show_backtrace(1);
5717 }
5718 {
5719 parser_prod__ASuperclass__n_annotations_61d(self, var_new_child); /* Direct call parser_prod#ASuperclass#n_annotations= on <self:ASuperclass>*/
5720 }
5721 goto RET_LABEL;
5722 } else {
5723 }
5724 RET_LABEL:;
5725 }
5726 /* method parser_prod#ASuperclass#replace_child for (self: Object, ANode, nullable ANode) */
5727 void VIRTUAL_parser_prod__ASuperclass__replace_child(val* self, val* p0, val* p1) {
5728 parser_prod__ASuperclass__replace_child(self, p0, p1); /* Direct call parser_prod#ASuperclass#replace_child on <self:Object(ASuperclass)>*/
5729 RET_LABEL:;
5730 }
5731 /* method parser_prod#ASuperclass#n_kwsuper= for (self: ASuperclass, TKwsuper) */
5732 void parser_prod__ASuperclass__n_kwsuper_61d(val* self, val* p0) {
5733 val* var_node /* var node: TKwsuper */;
5734 var_node = p0;
5735 self->attrs[COLOR_parser_nodes__ASuperclass___n_kwsuper].val = var_node; /* _n_kwsuper on <self:ASuperclass> */
5736 {
5737 { /* Inline parser_nodes#ANode#parent= (var_node,self) on <var_node:TKwsuper> */
5738 var_node->attrs[COLOR_parser_nodes__ANode___parent].val = self; /* _parent on <var_node:TKwsuper> */
5739 RET_LABEL1:(void)0;
5740 }
5741 }
5742 RET_LABEL:;
5743 }
5744 /* method parser_prod#ASuperclass#n_kwsuper= for (self: Object, TKwsuper) */
5745 void VIRTUAL_parser_prod__ASuperclass__n_kwsuper_61d(val* self, val* p0) {
5746 parser_prod__ASuperclass__n_kwsuper_61d(self, p0); /* Direct call parser_prod#ASuperclass#n_kwsuper= on <self:Object(ASuperclass)>*/
5747 RET_LABEL:;
5748 }
5749 /* method parser_prod#ASuperclass#n_type= for (self: ASuperclass, AType) */
5750 void parser_prod__ASuperclass__n_type_61d(val* self, val* p0) {
5751 val* var_node /* var node: AType */;
5752 var_node = p0;
5753 self->attrs[COLOR_parser_nodes__ASuperclass___n_type].val = var_node; /* _n_type on <self:ASuperclass> */
5754 {
5755 { /* Inline parser_nodes#ANode#parent= (var_node,self) on <var_node:AType> */
5756 var_node->attrs[COLOR_parser_nodes__ANode___parent].val = self; /* _parent on <var_node:AType> */
5757 RET_LABEL1:(void)0;
5758 }
5759 }
5760 RET_LABEL:;
5761 }
5762 /* method parser_prod#ASuperclass#n_type= for (self: Object, AType) */
5763 void VIRTUAL_parser_prod__ASuperclass__n_type_61d(val* self, val* p0) {
5764 parser_prod__ASuperclass__n_type_61d(self, p0); /* Direct call parser_prod#ASuperclass#n_type= on <self:Object(ASuperclass)>*/
5765 RET_LABEL:;
5766 }
5767 /* method parser_prod#ASuperclass#n_annotations= for (self: ASuperclass, nullable AAnnotations) */
5768 void parser_prod__ASuperclass__n_annotations_61d(val* self, val* p0) {
5769 val* var_node /* var node: nullable AAnnotations */;
5770 val* var /* : null */;
5771 short int var1 /* : Bool */;
5772 short int var2 /* : Bool */;
5773 val* var_other /* var other: nullable Object */;
5774 short int var4 /* : Bool */;
5775 short int var5 /* : Bool */;
5776 short int var6 /* : Bool */;
5777 var_node = p0;
5778 self->attrs[COLOR_parser_nodes__Prod___n_annotations].val = var_node; /* _n_annotations on <self:ASuperclass> */
5779 var = NULL;
5780 if (var_node == NULL) {
5781 var1 = 0; /* is null */
5782 } else {
5783 var1 = 1; /* arg is null and recv is not */
5784 }
5785 if (0) {
5786 { /* Inline kernel#Object#!= (var_node,var) on <var_node:nullable AAnnotations> */
5787 var_other = var;
5788 {
5789 var5 = ((short int (*)(val*, val*))(var_node->class->vft[COLOR_kernel__Object___61d_61d]))(var_node, var_other) /* == on <var_node:nullable AAnnotations(AAnnotations)>*/;
5790 var4 = var5;
5791 }
5792 var6 = !var4;
5793 var2 = var6;
5794 goto RET_LABEL3;
5795 RET_LABEL3:(void)0;
5796 }
5797 var1 = var2;
5798 }
5799 if (var1){
5800 {
5801 { /* Inline parser_nodes#ANode#parent= (var_node,self) on <var_node:nullable AAnnotations(AAnnotations)> */
5802 var_node->attrs[COLOR_parser_nodes__ANode___parent].val = self; /* _parent on <var_node:nullable AAnnotations(AAnnotations)> */
5803 RET_LABEL7:(void)0;
5804 }
5805 }
5806 } else {
5807 }
5808 RET_LABEL:;
5809 }
5810 /* method parser_prod#ASuperclass#n_annotations= for (self: Object, nullable AAnnotations) */
5811 void VIRTUAL_parser_prod__ASuperclass__n_annotations_61d(val* self, val* p0) {
5812 parser_prod__ASuperclass__n_annotations_61d(self, p0); /* Direct call parser_prod#ASuperclass#n_annotations= on <self:Object(ASuperclass)>*/
5813 RET_LABEL:;
5814 }
5815 /* method parser_prod#ASuperclass#visit_all for (self: ASuperclass, Visitor) */
5816 void parser_prod__ASuperclass__visit_all(val* self, val* p0) {
5817 val* var_v /* var v: Visitor */;
5818 val* var /* : TKwsuper */;
5819 val* var1 /* : AType */;
5820 val* var2 /* : nullable AAnnotations */;
5821 var_v = p0;
5822 var = self->attrs[COLOR_parser_nodes__ASuperclass___n_kwsuper].val; /* _n_kwsuper on <self:ASuperclass> */
5823 if (unlikely(var == NULL)) {
5824 PRINT_ERROR("Runtime error: %s", "Uninitialized attribute _n_kwsuper");
5825 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 831);
5826 show_backtrace(1);
5827 }
5828 {
5829 parser_nodes__Visitor__enter_visit(var_v, var); /* Direct call parser_nodes#Visitor#enter_visit on <var_v:Visitor>*/
5830 }
5831 var1 = self->attrs[COLOR_parser_nodes__ASuperclass___n_type].val; /* _n_type on <self:ASuperclass> */
5832 if (unlikely(var1 == NULL)) {
5833 PRINT_ERROR("Runtime error: %s", "Uninitialized attribute _n_type");
5834 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 832);
5835 show_backtrace(1);
5836 }
5837 {
5838 parser_nodes__Visitor__enter_visit(var_v, var1); /* Direct call parser_nodes#Visitor#enter_visit on <var_v:Visitor>*/
5839 }
5840 var2 = self->attrs[COLOR_parser_nodes__Prod___n_annotations].val; /* _n_annotations on <self:ASuperclass> */
5841 {
5842 parser_nodes__Visitor__enter_visit(var_v, var2); /* Direct call parser_nodes#Visitor#enter_visit on <var_v:Visitor>*/
5843 }
5844 RET_LABEL:;
5845 }
5846 /* method parser_prod#ASuperclass#visit_all for (self: Object, Visitor) */
5847 void VIRTUAL_parser_prod__ASuperclass__visit_all(val* self, val* p0) {
5848 parser_prod__ASuperclass__visit_all(self, p0); /* Direct call parser_prod#ASuperclass#visit_all on <self:Object(ASuperclass)>*/
5849 RET_LABEL:;
5850 }
5851 /* method parser_prod#AAttrPropdef#init_aattrpropdef for (self: AAttrPropdef, nullable ADoc, nullable AAble, nullable AAble, nullable TKwredef, nullable AVisibility, nullable TKwvar, nullable TAttrid, nullable TId, nullable AType, nullable AAnnotations, nullable AExpr) */
5852 void parser_prod__AAttrPropdef__init_aattrpropdef(val* self, val* p0, val* p1, val* p2, val* p3, val* p4, val* p5, val* p6, val* p7, val* p8, val* p9, val* p10) {
5853 val* var_n_doc /* var n_doc: nullable ADoc */;
5854 val* var_n_readable /* var n_readable: nullable AAble */;
5855 val* var_n_writable /* var n_writable: nullable AAble */;
5856 val* var_n_kwredef /* var n_kwredef: nullable TKwredef */;
5857 val* var_n_visibility /* var n_visibility: nullable AVisibility */;
5858 val* var_n_kwvar /* var n_kwvar: nullable TKwvar */;
5859 val* var_n_id /* var n_id: nullable TAttrid */;
5860 val* var_n_id2 /* var n_id2: nullable TId */;
5861 val* var_n_type /* var n_type: nullable AType */;
5862 val* var_n_annotations /* var n_annotations: nullable AAnnotations */;
5863 val* var_n_expr /* var n_expr: nullable AExpr */;
5864 val* var /* : null */;
5865 short int var1 /* : Bool */;
5866 short int var2 /* : Bool */;
5867 val* var_other /* var other: nullable Object */;
5868 short int var4 /* : Bool */;
5869 short int var5 /* : Bool */;
5870 short int var6 /* : Bool */;
5871 val* var8 /* : null */;
5872 short int var9 /* : Bool */;
5873 short int var10 /* : Bool */;
5874 short int var12 /* : Bool */;
5875 short int var13 /* : Bool */;
5876 short int var14 /* : Bool */;
5877 val* var16 /* : null */;
5878 short int var17 /* : Bool */;
5879 short int var18 /* : Bool */;
5880 short int var20 /* : Bool */;
5881 short int var21 /* : Bool */;
5882 short int var22 /* : Bool */;
5883 val* var24 /* : null */;
5884 short int var25 /* : Bool */;
5885 short int var26 /* : Bool */;
5886 short int var28 /* : Bool */;
5887 short int var29 /* : Bool */;
5888 short int var30 /* : Bool */;
5889 val* var34 /* : null */;
5890 short int var35 /* : Bool */;
5891 short int var36 /* : Bool */;
5892 short int var38 /* : Bool */;
5893 short int var39 /* : Bool */;
5894 short int var40 /* : Bool */;
5895 val* var42 /* : null */;
5896 short int var43 /* : Bool */;
5897 short int var44 /* : Bool */;
5898 short int var46 /* : Bool */;
5899 short int var47 /* : Bool */;
5900 short int var48 /* : Bool */;
5901 val* var50 /* : null */;
5902 short int var51 /* : Bool */;
5903 short int var52 /* : Bool */;
5904 short int var54 /* : Bool */;
5905 short int var55 /* : Bool */;
5906 short int var56 /* : Bool */;
5907 val* var58 /* : null */;
5908 short int var59 /* : Bool */;
5909 short int var60 /* : Bool */;
5910 short int var62 /* : Bool */;
5911 short int var63 /* : Bool */;
5912 short int var64 /* : Bool */;
5913 val* var66 /* : null */;
5914 short int var67 /* : Bool */;
5915 short int var68 /* : Bool */;
5916 short int var70 /* : Bool */;
5917 short int var71 /* : Bool */;
5918 short int var72 /* : Bool */;
5919 var_n_doc = p0;
5920 var_n_readable = p1;
5921 var_n_writable = p2;
5922 var_n_kwredef = p3;
5923 var_n_visibility = p4;
5924 var_n_kwvar = p5;
5925 var_n_id = p6;
5926 var_n_id2 = p7;
5927 var_n_type = p8;
5928 var_n_annotations = p9;
5929 var_n_expr = p10;
5930 self->attrs[COLOR_parser_nodes__APropdef___n_doc].val = var_n_doc; /* _n_doc on <self:AAttrPropdef> */
5931 var = NULL;
5932 if (var_n_doc == NULL) {
5933 var1 = 0; /* is null */
5934 } else {
5935 var1 = 1; /* arg is null and recv is not */
5936 }
5937 if (0) {
5938 { /* Inline kernel#Object#!= (var_n_doc,var) on <var_n_doc:nullable ADoc> */
5939 var_other = var;
5940 {
5941 var5 = ((short int (*)(val*, val*))(var_n_doc->class->vft[COLOR_kernel__Object___61d_61d]))(var_n_doc, var_other) /* == on <var_n_doc:nullable ADoc(ADoc)>*/;
5942 var4 = var5;
5943 }
5944 var6 = !var4;
5945 var2 = var6;
5946 goto RET_LABEL3;
5947 RET_LABEL3:(void)0;
5948 }
5949 var1 = var2;
5950 }
5951 if (var1){
5952 {
5953 { /* Inline parser_nodes#ANode#parent= (var_n_doc,self) on <var_n_doc:nullable ADoc(ADoc)> */
5954 var_n_doc->attrs[COLOR_parser_nodes__ANode___parent].val = self; /* _parent on <var_n_doc:nullable ADoc(ADoc)> */
5955 RET_LABEL7:(void)0;
5956 }
5957 }
5958 } else {
5959 }
5960 self->attrs[COLOR_parser_nodes__AAttrPropdef___n_readable].val = var_n_readable; /* _n_readable on <self:AAttrPropdef> */
5961 var8 = NULL;
5962 if (var_n_readable == NULL) {
5963 var9 = 0; /* is null */
5964 } else {
5965 var9 = 1; /* arg is null and recv is not */
5966 }
5967 if (0) {
5968 { /* Inline kernel#Object#!= (var_n_readable,var8) on <var_n_readable:nullable AAble> */
5969 var_other = var8;
5970 {
5971 var13 = ((short int (*)(val*, val*))(var_n_readable->class->vft[COLOR_kernel__Object___61d_61d]))(var_n_readable, var_other) /* == on <var_n_readable:nullable AAble(AAble)>*/;
5972 var12 = var13;
5973 }
5974 var14 = !var12;
5975 var10 = var14;
5976 goto RET_LABEL11;
5977 RET_LABEL11:(void)0;
5978 }
5979 var9 = var10;
5980 }
5981 if (var9){
5982 {
5983 { /* Inline parser_nodes#ANode#parent= (var_n_readable,self) on <var_n_readable:nullable AAble(AAble)> */
5984 var_n_readable->attrs[COLOR_parser_nodes__ANode___parent].val = self; /* _parent on <var_n_readable:nullable AAble(AAble)> */
5985 RET_LABEL15:(void)0;
5986 }
5987 }
5988 } else {
5989 }
5990 self->attrs[COLOR_parser_nodes__AAttrPropdef___n_writable].val = var_n_writable; /* _n_writable on <self:AAttrPropdef> */
5991 var16 = NULL;
5992 if (var_n_writable == NULL) {
5993 var17 = 0; /* is null */
5994 } else {
5995 var17 = 1; /* arg is null and recv is not */
5996 }
5997 if (0) {
5998 { /* Inline kernel#Object#!= (var_n_writable,var16) on <var_n_writable:nullable AAble> */
5999 var_other = var16;
6000 {
6001 var21 = ((short int (*)(val*, val*))(var_n_writable->class->vft[COLOR_kernel__Object___61d_61d]))(var_n_writable, var_other) /* == on <var_n_writable:nullable AAble(AAble)>*/;
6002 var20 = var21;
6003 }
6004 var22 = !var20;
6005 var18 = var22;
6006 goto RET_LABEL19;
6007 RET_LABEL19:(void)0;
6008 }
6009 var17 = var18;
6010 }
6011 if (var17){
6012 {
6013 { /* Inline parser_nodes#ANode#parent= (var_n_writable,self) on <var_n_writable:nullable AAble(AAble)> */
6014 var_n_writable->attrs[COLOR_parser_nodes__ANode___parent].val = self; /* _parent on <var_n_writable:nullable AAble(AAble)> */
6015 RET_LABEL23:(void)0;
6016 }
6017 }
6018 } else {
6019 }
6020 self->attrs[COLOR_parser_nodes__APropdef___n_kwredef].val = var_n_kwredef; /* _n_kwredef on <self:AAttrPropdef> */
6021 var24 = NULL;
6022 if (var_n_kwredef == NULL) {
6023 var25 = 0; /* is null */
6024 } else {
6025 var25 = 1; /* arg is null and recv is not */
6026 }
6027 if (0) {
6028 { /* Inline kernel#Object#!= (var_n_kwredef,var24) on <var_n_kwredef:nullable TKwredef> */
6029 var_other = var24;
6030 {
6031 var29 = ((short int (*)(val*, val*))(var_n_kwredef->class->vft[COLOR_kernel__Object___61d_61d]))(var_n_kwredef, var_other) /* == on <var_n_kwredef:nullable TKwredef(TKwredef)>*/;
6032 var28 = var29;
6033 }
6034 var30 = !var28;
6035 var26 = var30;
6036 goto RET_LABEL27;
6037 RET_LABEL27:(void)0;
6038 }
6039 var25 = var26;
6040 }
6041 if (var25){
6042 {
6043 { /* Inline parser_nodes#ANode#parent= (var_n_kwredef,self) on <var_n_kwredef:nullable TKwredef(TKwredef)> */
6044 var_n_kwredef->attrs[COLOR_parser_nodes__ANode___parent].val = self; /* _parent on <var_n_kwredef:nullable TKwredef(TKwredef)> */
6045 RET_LABEL31:(void)0;
6046 }
6047 }
6048 } else {
6049 }
6050 if (unlikely(var_n_visibility == NULL)) {
6051 PRINT_ERROR("Runtime error: %s", "Cast failed");
6052 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 859);
6053 show_backtrace(1);
6054 }
6055 self->attrs[COLOR_parser_nodes__APropdef___n_visibility].val = var_n_visibility; /* _n_visibility on <self:AAttrPropdef> */
6056 if (var_n_visibility == NULL) {
6057 PRINT_ERROR("Runtime error: %s", "Receiver is null");
6058 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 860);
6059 show_backtrace(1);
6060 } else {
6061 { /* Inline parser_nodes#ANode#parent= (var_n_visibility,self) on <var_n_visibility:nullable AVisibility> */
6062 if (unlikely(var_n_visibility == NULL)) {
6063 PRINT_ERROR("Runtime error: %s", "Receiver is null");
6064 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_nodes.nit", 38);
6065 show_backtrace(1);
6066 }
6067 var_n_visibility->attrs[COLOR_parser_nodes__ANode___parent].val = self; /* _parent on <var_n_visibility:nullable AVisibility> */
6068 RET_LABEL32:(void)0;
6069 }
6070 }
6071 if (unlikely(var_n_kwvar == NULL)) {
6072 PRINT_ERROR("Runtime error: %s", "Cast failed");
6073 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 861);
6074 show_backtrace(1);
6075 }
6076 self->attrs[COLOR_parser_nodes__AAttrPropdef___n_kwvar].val = var_n_kwvar; /* _n_kwvar on <self:AAttrPropdef> */
6077 if (var_n_kwvar == NULL) {
6078 PRINT_ERROR("Runtime error: %s", "Receiver is null");
6079 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 862);
6080 show_backtrace(1);
6081 } else {
6082 { /* Inline parser_nodes#ANode#parent= (var_n_kwvar,self) on <var_n_kwvar:nullable TKwvar> */
6083 if (unlikely(var_n_kwvar == NULL)) {
6084 PRINT_ERROR("Runtime error: %s", "Receiver is null");
6085 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_nodes.nit", 38);
6086 show_backtrace(1);
6087 }
6088 var_n_kwvar->attrs[COLOR_parser_nodes__ANode___parent].val = self; /* _parent on <var_n_kwvar:nullable TKwvar> */
6089 RET_LABEL33:(void)0;
6090 }
6091 }
6092 self->attrs[COLOR_parser_nodes__AAttrPropdef___n_id].val = var_n_id; /* _n_id on <self:AAttrPropdef> */
6093 var34 = NULL;
6094 if (var_n_id == NULL) {
6095 var35 = 0; /* is null */
6096 } else {
6097 var35 = 1; /* arg is null and recv is not */
6098 }
6099 if (0) {
6100 { /* Inline kernel#Object#!= (var_n_id,var34) on <var_n_id:nullable TAttrid> */
6101 var_other = var34;
6102 {
6103 var39 = ((short int (*)(val*, val*))(var_n_id->class->vft[COLOR_kernel__Object___61d_61d]))(var_n_id, var_other) /* == on <var_n_id:nullable TAttrid(TAttrid)>*/;
6104 var38 = var39;
6105 }
6106 var40 = !var38;
6107 var36 = var40;
6108 goto RET_LABEL37;
6109 RET_LABEL37:(void)0;
6110 }
6111 var35 = var36;
6112 }
6113 if (var35){
6114 {
6115 { /* Inline parser_nodes#ANode#parent= (var_n_id,self) on <var_n_id:nullable TAttrid(TAttrid)> */
6116 var_n_id->attrs[COLOR_parser_nodes__ANode___parent].val = self; /* _parent on <var_n_id:nullable TAttrid(TAttrid)> */
6117 RET_LABEL41:(void)0;
6118 }
6119 }
6120 } else {
6121 }
6122 self->attrs[COLOR_parser_nodes__AAttrPropdef___n_id2].val = var_n_id2; /* _n_id2 on <self:AAttrPropdef> */
6123 var42 = NULL;
6124 if (var_n_id2 == NULL) {
6125 var43 = 0; /* is null */
6126 } else {
6127 var43 = 1; /* arg is null and recv is not */
6128 }
6129 if (0) {
6130 { /* Inline kernel#Object#!= (var_n_id2,var42) on <var_n_id2:nullable TId> */
6131 var_other = var42;
6132 {
6133 var47 = ((short int (*)(val*, val*))(var_n_id2->class->vft[COLOR_kernel__Object___61d_61d]))(var_n_id2, var_other) /* == on <var_n_id2:nullable TId(TId)>*/;
6134 var46 = var47;
6135 }
6136 var48 = !var46;
6137 var44 = var48;
6138 goto RET_LABEL45;
6139 RET_LABEL45:(void)0;
6140 }
6141 var43 = var44;
6142 }
6143 if (var43){
6144 {
6145 { /* Inline parser_nodes#ANode#parent= (var_n_id2,self) on <var_n_id2:nullable TId(TId)> */
6146 var_n_id2->attrs[COLOR_parser_nodes__ANode___parent].val = self; /* _parent on <var_n_id2:nullable TId(TId)> */
6147 RET_LABEL49:(void)0;
6148 }
6149 }
6150 } else {
6151 }
6152 self->attrs[COLOR_parser_nodes__AAttrPropdef___n_type].val = var_n_type; /* _n_type on <self:AAttrPropdef> */
6153 var50 = NULL;
6154 if (var_n_type == NULL) {
6155 var51 = 0; /* is null */
6156 } else {
6157 var51 = 1; /* arg is null and recv is not */
6158 }
6159 if (0) {
6160 { /* Inline kernel#Object#!= (var_n_type,var50) on <var_n_type:nullable AType> */
6161 var_other = var50;
6162 {
6163 var55 = ((short int (*)(val*, val*))(var_n_type->class->vft[COLOR_kernel__Object___61d_61d]))(var_n_type, var_other) /* == on <var_n_type:nullable AType(AType)>*/;
6164 var54 = var55;
6165 }
6166 var56 = !var54;
6167 var52 = var56;
6168 goto RET_LABEL53;
6169 RET_LABEL53:(void)0;
6170 }
6171 var51 = var52;
6172 }
6173 if (var51){
6174 {
6175 { /* Inline parser_nodes#ANode#parent= (var_n_type,self) on <var_n_type:nullable AType(AType)> */
6176 var_n_type->attrs[COLOR_parser_nodes__ANode___parent].val = self; /* _parent on <var_n_type:nullable AType(AType)> */
6177 RET_LABEL57:(void)0;
6178 }
6179 }
6180 } else {
6181 }
6182 self->attrs[COLOR_parser_nodes__Prod___n_annotations].val = var_n_annotations; /* _n_annotations on <self:AAttrPropdef> */
6183 var58 = NULL;
6184 if (var_n_annotations == NULL) {
6185 var59 = 0; /* is null */
6186 } else {
6187 var59 = 1; /* arg is null and recv is not */
6188 }
6189 if (0) {
6190 { /* Inline kernel#Object#!= (var_n_annotations,var58) on <var_n_annotations:nullable AAnnotations> */
6191 var_other = var58;
6192 {
6193 var63 = ((short int (*)(val*, val*))(var_n_annotations->class->vft[COLOR_kernel__Object___61d_61d]))(var_n_annotations, var_other) /* == on <var_n_annotations:nullable AAnnotations(AAnnotations)>*/;
6194 var62 = var63;
6195 }
6196 var64 = !var62;
6197 var60 = var64;
6198 goto RET_LABEL61;
6199 RET_LABEL61:(void)0;
6200 }
6201 var59 = var60;
6202 }
6203 if (var59){
6204 {
6205 { /* Inline parser_nodes#ANode#parent= (var_n_annotations,self) on <var_n_annotations:nullable AAnnotations(AAnnotations)> */
6206 var_n_annotations->attrs[COLOR_parser_nodes__ANode___parent].val = self; /* _parent on <var_n_annotations:nullable AAnnotations(AAnnotations)> */
6207 RET_LABEL65:(void)0;
6208 }
6209 }
6210 } else {
6211 }
6212 self->attrs[COLOR_parser_nodes__AAttrPropdef___n_expr].val = var_n_expr; /* _n_expr on <self:AAttrPropdef> */
6213 var66 = NULL;
6214 if (var_n_expr == NULL) {
6215 var67 = 0; /* is null */
6216 } else {
6217 var67 = 1; /* arg is null and recv is not */
6218 }
6219 if (0) {
6220 { /* Inline kernel#Object#!= (var_n_expr,var66) on <var_n_expr:nullable AExpr> */
6221 var_other = var66;
6222 {
6223 var71 = ((short int (*)(val*, val*))(var_n_expr->class->vft[COLOR_kernel__Object___61d_61d]))(var_n_expr, var_other) /* == on <var_n_expr:nullable AExpr(AExpr)>*/;
6224 var70 = var71;
6225 }
6226 var72 = !var70;
6227 var68 = var72;
6228 goto RET_LABEL69;
6229 RET_LABEL69:(void)0;
6230 }
6231 var67 = var68;
6232 }
6233 if (var67){
6234 {
6235 { /* Inline parser_nodes#ANode#parent= (var_n_expr,self) on <var_n_expr:nullable AExpr(AExpr)> */
6236 var_n_expr->attrs[COLOR_parser_nodes__ANode___parent].val = self; /* _parent on <var_n_expr:nullable AExpr(AExpr)> */
6237 RET_LABEL73:(void)0;
6238 }
6239 }
6240 } else {
6241 }
6242 RET_LABEL:;
6243 }
6244 /* method parser_prod#AAttrPropdef#init_aattrpropdef for (self: Object, nullable ADoc, nullable AAble, nullable AAble, nullable TKwredef, nullable AVisibility, nullable TKwvar, nullable TAttrid, nullable TId, nullable AType, nullable AAnnotations, nullable AExpr) */
6245 void VIRTUAL_parser_prod__AAttrPropdef__init_aattrpropdef(val* self, val* p0, val* p1, val* p2, val* p3, val* p4, val* p5, val* p6, val* p7, val* p8, val* p9, val* p10) {
6246 parser_prod__AAttrPropdef__init_aattrpropdef(self, p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10); /* Direct call parser_prod#AAttrPropdef#init_aattrpropdef on <self:Object(AAttrPropdef)>*/
6247 RET_LABEL:;
6248 }
6249 /* method parser_prod#AAttrPropdef#replace_child for (self: AAttrPropdef, ANode, nullable ANode) */
6250 void parser_prod__AAttrPropdef__replace_child(val* self, val* p0, val* p1) {
6251 val* var_old_child /* var old_child: ANode */;
6252 val* var_new_child /* var new_child: nullable ANode */;
6253 val* var /* : nullable ADoc */;
6254 short int var1 /* : Bool */;
6255 short int var2 /* : Bool */;
6256 val* var_other /* var other: nullable Object */;
6257 short int var4 /* : Bool */;
6258 short int var6 /* : Bool */;
6259 short int var7 /* : Bool */;
6260 int cltype;
6261 int idtype;
6262 const char* var_class_name;
6263 val* var8 /* : nullable AAble */;
6264 short int var9 /* : Bool */;
6265 short int var10 /* : Bool */;
6266 short int var12 /* : Bool */;
6267 short int var14 /* : Bool */;
6268 short int var15 /* : Bool */;
6269 int cltype16;
6270 int idtype17;
6271 const char* var_class_name18;
6272 val* var19 /* : nullable AAble */;
6273 short int var20 /* : Bool */;
6274 short int var21 /* : Bool */;
6275 short int var23 /* : Bool */;
6276 short int var25 /* : Bool */;
6277 short int var26 /* : Bool */;
6278 int cltype27;
6279 int idtype28;
6280 const char* var_class_name29;
6281 val* var30 /* : nullable TKwredef */;
6282 short int var31 /* : Bool */;
6283 short int var32 /* : Bool */;
6284 short int var34 /* : Bool */;
6285 short int var36 /* : Bool */;
6286 short int var37 /* : Bool */;
6287 int cltype38;
6288 int idtype39;
6289 const char* var_class_name40;
6290 val* var41 /* : nullable AVisibility */;
6291 short int var42 /* : Bool */;
6292 short int var43 /* : Bool */;
6293 short int var45 /* : Bool */;
6294 short int var47 /* : Bool */;
6295 short int var48 /* : Bool */;
6296 int cltype49;
6297 int idtype50;
6298 const char* var_class_name51;
6299 val* var52 /* : TKwvar */;
6300 short int var53 /* : Bool */;
6301 short int var54 /* : Bool */;
6302 short int var56 /* : Bool */;
6303 short int var58 /* : Bool */;
6304 short int var59 /* : Bool */;
6305 int cltype60;
6306 int idtype61;
6307 const char* var_class_name62;
6308 val* var63 /* : nullable TAttrid */;
6309 short int var64 /* : Bool */;
6310 short int var65 /* : Bool */;
6311 short int var67 /* : Bool */;
6312 short int var69 /* : Bool */;
6313 short int var70 /* : Bool */;
6314 int cltype71;
6315 int idtype72;
6316 const char* var_class_name73;
6317 val* var74 /* : nullable TId */;
6318 short int var75 /* : Bool */;
6319 short int var76 /* : Bool */;
6320 short int var78 /* : Bool */;
6321 short int var80 /* : Bool */;
6322 short int var81 /* : Bool */;
6323 int cltype82;
6324 int idtype83;
6325 const char* var_class_name84;
6326 val* var85 /* : nullable AType */;
6327 short int var86 /* : Bool */;
6328 short int var87 /* : Bool */;
6329 short int var89 /* : Bool */;
6330 short int var91 /* : Bool */;
6331 short int var92 /* : Bool */;
6332 int cltype93;
6333 int idtype94;
6334 const char* var_class_name95;
6335 val* var96 /* : nullable AAnnotations */;
6336 short int var97 /* : Bool */;
6337 short int var98 /* : Bool */;
6338 short int var100 /* : Bool */;
6339 short int var102 /* : Bool */;
6340 short int var103 /* : Bool */;
6341 int cltype104;
6342 int idtype105;
6343 const char* var_class_name106;
6344 val* var107 /* : nullable AExpr */;
6345 short int var108 /* : Bool */;
6346 short int var109 /* : Bool */;
6347 short int var111 /* : Bool */;
6348 short int var113 /* : Bool */;
6349 short int var114 /* : Bool */;
6350 int cltype115;
6351 int idtype116;
6352 const char* var_class_name117;
6353 var_old_child = p0;
6354 var_new_child = p1;
6355 var = self->attrs[COLOR_parser_nodes__APropdef___n_doc].val; /* _n_doc on <self:AAttrPropdef> */
6356 if (var == NULL) {
6357 var1 = 0; /* <var_old_child:ANode> cannot be null */
6358 } else {
6359 { /* Inline kernel#Object#== (var,var_old_child) on <var:nullable ADoc> */
6360 var_other = var_old_child;
6361 {
6362 { /* Inline kernel#Object#is_same_instance (var,var_other) on <var:nullable ADoc(ADoc)> */
6363 var6 = var == var_other;
6364 var4 = var6;
6365 goto RET_LABEL5;
6366 RET_LABEL5:(void)0;
6367 }
6368 }
6369 var2 = var4;
6370 goto RET_LABEL3;
6371 RET_LABEL3:(void)0;
6372 }
6373 var1 = var2;
6374 }
6375 if (var1){
6376 /* <var_new_child:nullable ANode> isa nullable ADoc */
6377 cltype = type_nullable_parser_nodes__ADoc.color;
6378 idtype = type_nullable_parser_nodes__ADoc.id;
6379 if(var_new_child == NULL) {
6380 var7 = 1;
6381 } else {
6382 if(cltype >= var_new_child->type->table_size) {
6383 var7 = 0;
6384 } else {
6385 var7 = var_new_child->type->type_table[cltype] == idtype;
6386 }
6387 }
6388 if (unlikely(!var7)) {
6389 var_class_name = var_new_child == NULL ? "null" : var_new_child->type->name;
6390 PRINT_ERROR("Runtime error: Cast failed. Expected `%s`, got `%s`", "nullable ADoc", var_class_name);
6391 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 878);
6392 show_backtrace(1);
6393 }
6394 {
6395 parser_prod__AAttrPropdef__n_doc_61d(self, var_new_child); /* Direct call parser_prod#AAttrPropdef#n_doc= on <self:AAttrPropdef>*/
6396 }
6397 goto RET_LABEL;
6398 } else {
6399 }
6400 var8 = self->attrs[COLOR_parser_nodes__AAttrPropdef___n_readable].val; /* _n_readable on <self:AAttrPropdef> */
6401 if (var8 == NULL) {
6402 var9 = 0; /* <var_old_child:ANode> cannot be null */
6403 } else {
6404 { /* Inline kernel#Object#== (var8,var_old_child) on <var8:nullable AAble> */
6405 var_other = var_old_child;
6406 {
6407 { /* Inline kernel#Object#is_same_instance (var8,var_other) on <var8:nullable AAble(AAble)> */
6408 var14 = var8 == var_other;
6409 var12 = var14;
6410 goto RET_LABEL13;
6411 RET_LABEL13:(void)0;
6412 }
6413 }
6414 var10 = var12;
6415 goto RET_LABEL11;
6416 RET_LABEL11:(void)0;
6417 }
6418 var9 = var10;
6419 }
6420 if (var9){
6421 /* <var_new_child:nullable ANode> isa nullable AAble */
6422 cltype16 = type_nullable_parser_nodes__AAble.color;
6423 idtype17 = type_nullable_parser_nodes__AAble.id;
6424 if(var_new_child == NULL) {
6425 var15 = 1;
6426 } else {
6427 if(cltype16 >= var_new_child->type->table_size) {
6428 var15 = 0;
6429 } else {
6430 var15 = var_new_child->type->type_table[cltype16] == idtype17;
6431 }
6432 }
6433 if (unlikely(!var15)) {
6434 var_class_name18 = var_new_child == NULL ? "null" : var_new_child->type->name;
6435 PRINT_ERROR("Runtime error: Cast failed. Expected `%s`, got `%s`", "nullable AAble", var_class_name18);
6436 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 882);
6437 show_backtrace(1);
6438 }
6439 {
6440 parser_prod__AAttrPropdef__n_readable_61d(self, var_new_child); /* Direct call parser_prod#AAttrPropdef#n_readable= on <self:AAttrPropdef>*/
6441 }
6442 goto RET_LABEL;
6443 } else {
6444 }
6445 var19 = self->attrs[COLOR_parser_nodes__AAttrPropdef___n_writable].val; /* _n_writable on <self:AAttrPropdef> */
6446 if (var19 == NULL) {
6447 var20 = 0; /* <var_old_child:ANode> cannot be null */
6448 } else {
6449 { /* Inline kernel#Object#== (var19,var_old_child) on <var19:nullable AAble> */
6450 var_other = var_old_child;
6451 {
6452 { /* Inline kernel#Object#is_same_instance (var19,var_other) on <var19:nullable AAble(AAble)> */
6453 var25 = var19 == var_other;
6454 var23 = var25;
6455 goto RET_LABEL24;
6456 RET_LABEL24:(void)0;
6457 }
6458 }
6459 var21 = var23;
6460 goto RET_LABEL22;
6461 RET_LABEL22:(void)0;
6462 }
6463 var20 = var21;
6464 }
6465 if (var20){
6466 /* <var_new_child:nullable ANode> isa nullable AAble */
6467 cltype27 = type_nullable_parser_nodes__AAble.color;
6468 idtype28 = type_nullable_parser_nodes__AAble.id;
6469 if(var_new_child == NULL) {
6470 var26 = 1;
6471 } else {
6472 if(cltype27 >= var_new_child->type->table_size) {
6473 var26 = 0;
6474 } else {
6475 var26 = var_new_child->type->type_table[cltype27] == idtype28;
6476 }
6477 }
6478 if (unlikely(!var26)) {
6479 var_class_name29 = var_new_child == NULL ? "null" : var_new_child->type->name;
6480 PRINT_ERROR("Runtime error: Cast failed. Expected `%s`, got `%s`", "nullable AAble", var_class_name29);
6481 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 886);
6482 show_backtrace(1);
6483 }
6484 {
6485 parser_prod__AAttrPropdef__n_writable_61d(self, var_new_child); /* Direct call parser_prod#AAttrPropdef#n_writable= on <self:AAttrPropdef>*/
6486 }
6487 goto RET_LABEL;
6488 } else {
6489 }
6490 var30 = self->attrs[COLOR_parser_nodes__APropdef___n_kwredef].val; /* _n_kwredef on <self:AAttrPropdef> */
6491 if (var30 == NULL) {
6492 var31 = 0; /* <var_old_child:ANode> cannot be null */
6493 } else {
6494 { /* Inline kernel#Object#== (var30,var_old_child) on <var30:nullable TKwredef> */
6495 var_other = var_old_child;
6496 {
6497 { /* Inline kernel#Object#is_same_instance (var30,var_other) on <var30:nullable TKwredef(TKwredef)> */
6498 var36 = var30 == var_other;
6499 var34 = var36;
6500 goto RET_LABEL35;
6501 RET_LABEL35:(void)0;
6502 }
6503 }
6504 var32 = var34;
6505 goto RET_LABEL33;
6506 RET_LABEL33:(void)0;
6507 }
6508 var31 = var32;
6509 }
6510 if (var31){
6511 /* <var_new_child:nullable ANode> isa nullable TKwredef */
6512 cltype38 = type_nullable_parser_nodes__TKwredef.color;
6513 idtype39 = type_nullable_parser_nodes__TKwredef.id;
6514 if(var_new_child == NULL) {
6515 var37 = 1;
6516 } else {
6517 if(cltype38 >= var_new_child->type->table_size) {
6518 var37 = 0;
6519 } else {
6520 var37 = var_new_child->type->type_table[cltype38] == idtype39;
6521 }
6522 }
6523 if (unlikely(!var37)) {
6524 var_class_name40 = var_new_child == NULL ? "null" : var_new_child->type->name;
6525 PRINT_ERROR("Runtime error: Cast failed. Expected `%s`, got `%s`", "nullable TKwredef", var_class_name40);
6526 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 890);
6527 show_backtrace(1);
6528 }
6529 {
6530 parser_prod__AAttrPropdef__n_kwredef_61d(self, var_new_child); /* Direct call parser_prod#AAttrPropdef#n_kwredef= on <self:AAttrPropdef>*/
6531 }
6532 goto RET_LABEL;
6533 } else {
6534 }
6535 var41 = self->attrs[COLOR_parser_nodes__APropdef___n_visibility].val; /* _n_visibility on <self:AAttrPropdef> */
6536 if (var41 == NULL) {
6537 var42 = 0; /* <var_old_child:ANode> cannot be null */
6538 } else {
6539 { /* Inline kernel#Object#== (var41,var_old_child) on <var41:nullable AVisibility> */
6540 var_other = var_old_child;
6541 {
6542 { /* Inline kernel#Object#is_same_instance (var41,var_other) on <var41:nullable AVisibility(AVisibility)> */
6543 var47 = var41 == var_other;
6544 var45 = var47;
6545 goto RET_LABEL46;
6546 RET_LABEL46:(void)0;
6547 }
6548 }
6549 var43 = var45;
6550 goto RET_LABEL44;
6551 RET_LABEL44:(void)0;
6552 }
6553 var42 = var43;
6554 }
6555 if (var42){
6556 /* <var_new_child:nullable ANode> isa AVisibility */
6557 cltype49 = type_parser_nodes__AVisibility.color;
6558 idtype50 = type_parser_nodes__AVisibility.id;
6559 if(var_new_child == NULL) {
6560 var48 = 0;
6561 } else {
6562 if(cltype49 >= var_new_child->type->table_size) {
6563 var48 = 0;
6564 } else {
6565 var48 = var_new_child->type->type_table[cltype49] == idtype50;
6566 }
6567 }
6568 if (unlikely(!var48)) {
6569 var_class_name51 = var_new_child == NULL ? "null" : var_new_child->type->name;
6570 PRINT_ERROR("Runtime error: Cast failed. Expected `%s`, got `%s`", "AVisibility", var_class_name51);
6571 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 894);
6572 show_backtrace(1);
6573 }
6574 {
6575 parser_prod__AAttrPropdef__n_visibility_61d(self, var_new_child); /* Direct call parser_prod#AAttrPropdef#n_visibility= on <self:AAttrPropdef>*/
6576 }
6577 goto RET_LABEL;
6578 } else {
6579 }
6580 var52 = self->attrs[COLOR_parser_nodes__AAttrPropdef___n_kwvar].val; /* _n_kwvar on <self:AAttrPropdef> */
6581 if (unlikely(var52 == NULL)) {
6582 PRINT_ERROR("Runtime error: %s", "Uninitialized attribute _n_kwvar");
6583 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 897);
6584 show_backtrace(1);
6585 }
6586 {
6587 { /* Inline kernel#Object#== (var52,var_old_child) on <var52:TKwvar> */
6588 var_other = var_old_child;
6589 {
6590 { /* Inline kernel#Object#is_same_instance (var52,var_other) on <var52:TKwvar> */
6591 var58 = var52 == var_other;
6592 var56 = var58;
6593 goto RET_LABEL57;
6594 RET_LABEL57:(void)0;
6595 }
6596 }
6597 var54 = var56;
6598 goto RET_LABEL55;
6599 RET_LABEL55:(void)0;
6600 }
6601 var53 = var54;
6602 }
6603 if (var53){
6604 /* <var_new_child:nullable ANode> isa TKwvar */
6605 cltype60 = type_parser_nodes__TKwvar.color;
6606 idtype61 = type_parser_nodes__TKwvar.id;
6607 if(var_new_child == NULL) {
6608 var59 = 0;
6609 } else {
6610 if(cltype60 >= var_new_child->type->table_size) {
6611 var59 = 0;
6612 } else {
6613 var59 = var_new_child->type->type_table[cltype60] == idtype61;
6614 }
6615 }
6616 if (unlikely(!var59)) {
6617 var_class_name62 = var_new_child == NULL ? "null" : var_new_child->type->name;
6618 PRINT_ERROR("Runtime error: Cast failed. Expected `%s`, got `%s`", "TKwvar", var_class_name62);
6619 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 898);
6620 show_backtrace(1);
6621 }
6622 {
6623 parser_prod__AAttrPropdef__n_kwvar_61d(self, var_new_child); /* Direct call parser_prod#AAttrPropdef#n_kwvar= on <self:AAttrPropdef>*/
6624 }
6625 goto RET_LABEL;
6626 } else {
6627 }
6628 var63 = self->attrs[COLOR_parser_nodes__AAttrPropdef___n_id].val; /* _n_id on <self:AAttrPropdef> */
6629 if (var63 == NULL) {
6630 var64 = 0; /* <var_old_child:ANode> cannot be null */
6631 } else {
6632 { /* Inline kernel#Object#== (var63,var_old_child) on <var63:nullable TAttrid> */
6633 var_other = var_old_child;
6634 {
6635 { /* Inline kernel#Object#is_same_instance (var63,var_other) on <var63:nullable TAttrid(TAttrid)> */
6636 var69 = var63 == var_other;
6637 var67 = var69;
6638 goto RET_LABEL68;
6639 RET_LABEL68:(void)0;
6640 }
6641 }
6642 var65 = var67;
6643 goto RET_LABEL66;
6644 RET_LABEL66:(void)0;
6645 }
6646 var64 = var65;
6647 }
6648 if (var64){
6649 /* <var_new_child:nullable ANode> isa nullable TAttrid */
6650 cltype71 = type_nullable_parser_nodes__TAttrid.color;
6651 idtype72 = type_nullable_parser_nodes__TAttrid.id;
6652 if(var_new_child == NULL) {
6653 var70 = 1;
6654 } else {
6655 if(cltype71 >= var_new_child->type->table_size) {
6656 var70 = 0;
6657 } else {
6658 var70 = var_new_child->type->type_table[cltype71] == idtype72;
6659 }
6660 }
6661 if (unlikely(!var70)) {
6662 var_class_name73 = var_new_child == NULL ? "null" : var_new_child->type->name;
6663 PRINT_ERROR("Runtime error: Cast failed. Expected `%s`, got `%s`", "nullable TAttrid", var_class_name73);
6664 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 902);
6665 show_backtrace(1);
6666 }
6667 {
6668 parser_prod__AAttrPropdef__n_id_61d(self, var_new_child); /* Direct call parser_prod#AAttrPropdef#n_id= on <self:AAttrPropdef>*/
6669 }
6670 goto RET_LABEL;
6671 } else {
6672 }
6673 var74 = self->attrs[COLOR_parser_nodes__AAttrPropdef___n_id2].val; /* _n_id2 on <self:AAttrPropdef> */
6674 if (var74 == NULL) {
6675 var75 = 0; /* <var_old_child:ANode> cannot be null */
6676 } else {
6677 { /* Inline kernel#Object#== (var74,var_old_child) on <var74:nullable TId> */
6678 var_other = var_old_child;
6679 {
6680 { /* Inline kernel#Object#is_same_instance (var74,var_other) on <var74:nullable TId(TId)> */
6681 var80 = var74 == var_other;
6682 var78 = var80;
6683 goto RET_LABEL79;
6684 RET_LABEL79:(void)0;
6685 }
6686 }
6687 var76 = var78;
6688 goto RET_LABEL77;
6689 RET_LABEL77:(void)0;
6690 }
6691 var75 = var76;
6692 }
6693 if (var75){
6694 /* <var_new_child:nullable ANode> isa nullable TId */
6695 cltype82 = type_nullable_parser_nodes__TId.color;
6696 idtype83 = type_nullable_parser_nodes__TId.id;
6697 if(var_new_child == NULL) {
6698 var81 = 1;
6699 } else {
6700 if(cltype82 >= var_new_child->type->table_size) {
6701 var81 = 0;
6702 } else {
6703 var81 = var_new_child->type->type_table[cltype82] == idtype83;
6704 }
6705 }
6706 if (unlikely(!var81)) {
6707 var_class_name84 = var_new_child == NULL ? "null" : var_new_child->type->name;
6708 PRINT_ERROR("Runtime error: Cast failed. Expected `%s`, got `%s`", "nullable TId", var_class_name84);
6709 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 906);
6710 show_backtrace(1);
6711 }
6712 {
6713 parser_prod__AAttrPropdef__n_id2_61d(self, var_new_child); /* Direct call parser_prod#AAttrPropdef#n_id2= on <self:AAttrPropdef>*/
6714 }
6715 goto RET_LABEL;
6716 } else {
6717 }
6718 var85 = self->attrs[COLOR_parser_nodes__AAttrPropdef___n_type].val; /* _n_type on <self:AAttrPropdef> */
6719 if (var85 == NULL) {
6720 var86 = 0; /* <var_old_child:ANode> cannot be null */
6721 } else {
6722 { /* Inline kernel#Object#== (var85,var_old_child) on <var85:nullable AType> */
6723 var_other = var_old_child;
6724 {
6725 { /* Inline kernel#Object#is_same_instance (var85,var_other) on <var85:nullable AType(AType)> */
6726 var91 = var85 == var_other;
6727 var89 = var91;
6728 goto RET_LABEL90;
6729 RET_LABEL90:(void)0;
6730 }
6731 }
6732 var87 = var89;
6733 goto RET_LABEL88;
6734 RET_LABEL88:(void)0;
6735 }
6736 var86 = var87;
6737 }
6738 if (var86){
6739 /* <var_new_child:nullable ANode> isa nullable AType */
6740 cltype93 = type_nullable_parser_nodes__AType.color;
6741 idtype94 = type_nullable_parser_nodes__AType.id;
6742 if(var_new_child == NULL) {
6743 var92 = 1;
6744 } else {
6745 if(cltype93 >= var_new_child->type->table_size) {
6746 var92 = 0;
6747 } else {
6748 var92 = var_new_child->type->type_table[cltype93] == idtype94;
6749 }
6750 }
6751 if (unlikely(!var92)) {
6752 var_class_name95 = var_new_child == NULL ? "null" : var_new_child->type->name;
6753 PRINT_ERROR("Runtime error: Cast failed. Expected `%s`, got `%s`", "nullable AType", var_class_name95);
6754 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 910);
6755 show_backtrace(1);
6756 }
6757 {
6758 parser_prod__AAttrPropdef__n_type_61d(self, var_new_child); /* Direct call parser_prod#AAttrPropdef#n_type= on <self:AAttrPropdef>*/
6759 }
6760 goto RET_LABEL;
6761 } else {
6762 }
6763 var96 = self->attrs[COLOR_parser_nodes__Prod___n_annotations].val; /* _n_annotations on <self:AAttrPropdef> */
6764 if (var96 == NULL) {
6765 var97 = 0; /* <var_old_child:ANode> cannot be null */
6766 } else {
6767 { /* Inline kernel#Object#== (var96,var_old_child) on <var96:nullable AAnnotations> */
6768 var_other = var_old_child;
6769 {
6770 { /* Inline kernel#Object#is_same_instance (var96,var_other) on <var96:nullable AAnnotations(AAnnotations)> */
6771 var102 = var96 == var_other;
6772 var100 = var102;
6773 goto RET_LABEL101;
6774 RET_LABEL101:(void)0;
6775 }
6776 }
6777 var98 = var100;
6778 goto RET_LABEL99;
6779 RET_LABEL99:(void)0;
6780 }
6781 var97 = var98;
6782 }
6783 if (var97){
6784 /* <var_new_child:nullable ANode> isa nullable AAnnotations */
6785 cltype104 = type_nullable_parser_nodes__AAnnotations.color;
6786 idtype105 = type_nullable_parser_nodes__AAnnotations.id;
6787 if(var_new_child == NULL) {
6788 var103 = 1;
6789 } else {
6790 if(cltype104 >= var_new_child->type->table_size) {
6791 var103 = 0;
6792 } else {
6793 var103 = var_new_child->type->type_table[cltype104] == idtype105;
6794 }
6795 }
6796 if (unlikely(!var103)) {
6797 var_class_name106 = var_new_child == NULL ? "null" : var_new_child->type->name;
6798 PRINT_ERROR("Runtime error: Cast failed. Expected `%s`, got `%s`", "nullable AAnnotations", var_class_name106);
6799 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 914);
6800 show_backtrace(1);
6801 }
6802 {
6803 parser_prod__AAttrPropdef__n_annotations_61d(self, var_new_child); /* Direct call parser_prod#AAttrPropdef#n_annotations= on <self:AAttrPropdef>*/
6804 }
6805 goto RET_LABEL;
6806 } else {
6807 }
6808 var107 = self->attrs[COLOR_parser_nodes__AAttrPropdef___n_expr].val; /* _n_expr on <self:AAttrPropdef> */
6809 if (var107 == NULL) {
6810 var108 = 0; /* <var_old_child:ANode> cannot be null */
6811 } else {
6812 { /* Inline kernel#Object#== (var107,var_old_child) on <var107:nullable AExpr> */
6813 var_other = var_old_child;
6814 {
6815 { /* Inline kernel#Object#is_same_instance (var107,var_other) on <var107:nullable AExpr(AExpr)> */
6816 var113 = var107 == var_other;
6817 var111 = var113;
6818 goto RET_LABEL112;
6819 RET_LABEL112:(void)0;
6820 }
6821 }
6822 var109 = var111;
6823 goto RET_LABEL110;
6824 RET_LABEL110:(void)0;
6825 }
6826 var108 = var109;
6827 }
6828 if (var108){
6829 /* <var_new_child:nullable ANode> isa nullable AExpr */
6830 cltype115 = type_nullable_parser_nodes__AExpr.color;
6831 idtype116 = type_nullable_parser_nodes__AExpr.id;
6832 if(var_new_child == NULL) {
6833 var114 = 1;
6834 } else {
6835 if(cltype115 >= var_new_child->type->table_size) {
6836 var114 = 0;
6837 } else {
6838 var114 = var_new_child->type->type_table[cltype115] == idtype116;
6839 }
6840 }
6841 if (unlikely(!var114)) {
6842 var_class_name117 = var_new_child == NULL ? "null" : var_new_child->type->name;
6843 PRINT_ERROR("Runtime error: Cast failed. Expected `%s`, got `%s`", "nullable AExpr", var_class_name117);
6844 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 918);
6845 show_backtrace(1);
6846 }
6847 {
6848 parser_prod__AAttrPropdef__n_expr_61d(self, var_new_child); /* Direct call parser_prod#AAttrPropdef#n_expr= on <self:AAttrPropdef>*/
6849 }
6850 goto RET_LABEL;
6851 } else {
6852 }
6853 RET_LABEL:;
6854 }
6855 /* method parser_prod#AAttrPropdef#replace_child for (self: Object, ANode, nullable ANode) */
6856 void VIRTUAL_parser_prod__AAttrPropdef__replace_child(val* self, val* p0, val* p1) {
6857 parser_prod__AAttrPropdef__replace_child(self, p0, p1); /* Direct call parser_prod#AAttrPropdef#replace_child on <self:Object(AAttrPropdef)>*/
6858 RET_LABEL:;
6859 }
6860 /* method parser_prod#AAttrPropdef#n_doc= for (self: AAttrPropdef, nullable ADoc) */
6861 void parser_prod__AAttrPropdef__n_doc_61d(val* self, val* p0) {
6862 val* var_node /* var node: nullable ADoc */;
6863 val* var /* : null */;
6864 short int var1 /* : Bool */;
6865 short int var2 /* : Bool */;
6866 val* var_other /* var other: nullable Object */;
6867 short int var4 /* : Bool */;
6868 short int var5 /* : Bool */;
6869 short int var6 /* : Bool */;
6870 var_node = p0;
6871 self->attrs[COLOR_parser_nodes__APropdef___n_doc].val = var_node; /* _n_doc on <self:AAttrPropdef> */
6872 var = NULL;
6873 if (var_node == NULL) {
6874 var1 = 0; /* is null */
6875 } else {
6876 var1 = 1; /* arg is null and recv is not */
6877 }
6878 if (0) {
6879 { /* Inline kernel#Object#!= (var_node,var) on <var_node:nullable ADoc> */
6880 var_other = var;
6881 {
6882 var5 = ((short int (*)(val*, val*))(var_node->class->vft[COLOR_kernel__Object___61d_61d]))(var_node, var_other) /* == on <var_node:nullable ADoc(ADoc)>*/;
6883 var4 = var5;
6884 }
6885 var6 = !var4;
6886 var2 = var6;
6887 goto RET_LABEL3;
6888 RET_LABEL3:(void)0;
6889 }
6890 var1 = var2;
6891 }
6892 if (var1){
6893 {
6894 { /* Inline parser_nodes#ANode#parent= (var_node,self) on <var_node:nullable ADoc(ADoc)> */
6895 var_node->attrs[COLOR_parser_nodes__ANode___parent].val = self; /* _parent on <var_node:nullable ADoc(ADoc)> */
6896 RET_LABEL7:(void)0;
6897 }
6898 }
6899 } else {
6900 }
6901 RET_LABEL:;
6902 }
6903 /* method parser_prod#AAttrPropdef#n_doc= for (self: Object, nullable ADoc) */
6904 void VIRTUAL_parser_prod__AAttrPropdef__n_doc_61d(val* self, val* p0) {
6905 parser_prod__AAttrPropdef__n_doc_61d(self, p0); /* Direct call parser_prod#AAttrPropdef#n_doc= on <self:Object(AAttrPropdef)>*/
6906 RET_LABEL:;
6907 }
6908 /* method parser_prod#AAttrPropdef#n_readable= for (self: AAttrPropdef, nullable AAble) */
6909 void parser_prod__AAttrPropdef__n_readable_61d(val* self, val* p0) {
6910 val* var_node /* var node: nullable AAble */;
6911 val* var /* : null */;
6912 short int var1 /* : Bool */;
6913 short int var2 /* : Bool */;
6914 val* var_other /* var other: nullable Object */;
6915 short int var4 /* : Bool */;
6916 short int var5 /* : Bool */;
6917 short int var6 /* : Bool */;
6918 var_node = p0;
6919 self->attrs[COLOR_parser_nodes__AAttrPropdef___n_readable].val = var_node; /* _n_readable on <self:AAttrPropdef> */
6920 var = NULL;
6921 if (var_node == NULL) {
6922 var1 = 0; /* is null */
6923 } else {
6924 var1 = 1; /* arg is null and recv is not */
6925 }
6926 if (0) {
6927 { /* Inline kernel#Object#!= (var_node,var) on <var_node:nullable AAble> */
6928 var_other = var;
6929 {
6930 var5 = ((short int (*)(val*, val*))(var_node->class->vft[COLOR_kernel__Object___61d_61d]))(var_node, var_other) /* == on <var_node:nullable AAble(AAble)>*/;
6931 var4 = var5;
6932 }
6933 var6 = !var4;
6934 var2 = var6;
6935 goto RET_LABEL3;
6936 RET_LABEL3:(void)0;
6937 }
6938 var1 = var2;
6939 }
6940 if (var1){
6941 {
6942 { /* Inline parser_nodes#ANode#parent= (var_node,self) on <var_node:nullable AAble(AAble)> */
6943 var_node->attrs[COLOR_parser_nodes__ANode___parent].val = self; /* _parent on <var_node:nullable AAble(AAble)> */
6944 RET_LABEL7:(void)0;
6945 }
6946 }
6947 } else {
6948 }
6949 RET_LABEL:;
6950 }
6951 /* method parser_prod#AAttrPropdef#n_readable= for (self: Object, nullable AAble) */
6952 void VIRTUAL_parser_prod__AAttrPropdef__n_readable_61d(val* self, val* p0) {
6953 parser_prod__AAttrPropdef__n_readable_61d(self, p0); /* Direct call parser_prod#AAttrPropdef#n_readable= on <self:Object(AAttrPropdef)>*/
6954 RET_LABEL:;
6955 }
6956 /* method parser_prod#AAttrPropdef#n_writable= for (self: AAttrPropdef, nullable AAble) */
6957 void parser_prod__AAttrPropdef__n_writable_61d(val* self, val* p0) {
6958 val* var_node /* var node: nullable AAble */;
6959 val* var /* : null */;
6960 short int var1 /* : Bool */;
6961 short int var2 /* : Bool */;
6962 val* var_other /* var other: nullable Object */;
6963 short int var4 /* : Bool */;
6964 short int var5 /* : Bool */;
6965 short int var6 /* : Bool */;
6966 var_node = p0;
6967 self->attrs[COLOR_parser_nodes__AAttrPropdef___n_writable].val = var_node; /* _n_writable on <self:AAttrPropdef> */
6968 var = NULL;
6969 if (var_node == NULL) {
6970 var1 = 0; /* is null */
6971 } else {
6972 var1 = 1; /* arg is null and recv is not */
6973 }
6974 if (0) {
6975 { /* Inline kernel#Object#!= (var_node,var) on <var_node:nullable AAble> */
6976 var_other = var;
6977 {
6978 var5 = ((short int (*)(val*, val*))(var_node->class->vft[COLOR_kernel__Object___61d_61d]))(var_node, var_other) /* == on <var_node:nullable AAble(AAble)>*/;
6979 var4 = var5;
6980 }
6981 var6 = !var4;
6982 var2 = var6;
6983 goto RET_LABEL3;
6984 RET_LABEL3:(void)0;
6985 }
6986 var1 = var2;
6987 }
6988 if (var1){
6989 {
6990 { /* Inline parser_nodes#ANode#parent= (var_node,self) on <var_node:nullable AAble(AAble)> */
6991 var_node->attrs[COLOR_parser_nodes__ANode___parent].val = self; /* _parent on <var_node:nullable AAble(AAble)> */
6992 RET_LABEL7:(void)0;
6993 }
6994 }
6995 } else {
6996 }
6997 RET_LABEL:;
6998 }
6999 /* method parser_prod#AAttrPropdef#n_writable= for (self: Object, nullable AAble) */
7000 void VIRTUAL_parser_prod__AAttrPropdef__n_writable_61d(val* self, val* p0) {
7001 parser_prod__AAttrPropdef__n_writable_61d(self, p0); /* Direct call parser_prod#AAttrPropdef#n_writable= on <self:Object(AAttrPropdef)>*/
7002 RET_LABEL:;
7003 }
7004 /* method parser_prod#AAttrPropdef#n_kwredef= for (self: AAttrPropdef, nullable TKwredef) */
7005 void parser_prod__AAttrPropdef__n_kwredef_61d(val* self, val* p0) {
7006 val* var_node /* var node: nullable TKwredef */;
7007 val* var /* : null */;
7008 short int var1 /* : Bool */;
7009 short int var2 /* : Bool */;
7010 val* var_other /* var other: nullable Object */;
7011 short int var4 /* : Bool */;
7012 short int var5 /* : Bool */;
7013 short int var6 /* : Bool */;
7014 var_node = p0;
7015 self->attrs[COLOR_parser_nodes__APropdef___n_kwredef].val = var_node; /* _n_kwredef on <self:AAttrPropdef> */
7016 var = NULL;
7017 if (var_node == NULL) {
7018 var1 = 0; /* is null */
7019 } else {
7020 var1 = 1; /* arg is null and recv is not */
7021 }
7022 if (0) {
7023 { /* Inline kernel#Object#!= (var_node,var) on <var_node:nullable TKwredef> */
7024 var_other = var;
7025 {
7026 var5 = ((short int (*)(val*, val*))(var_node->class->vft[COLOR_kernel__Object___61d_61d]))(var_node, var_other) /* == on <var_node:nullable TKwredef(TKwredef)>*/;
7027 var4 = var5;
7028 }
7029 var6 = !var4;
7030 var2 = var6;
7031 goto RET_LABEL3;
7032 RET_LABEL3:(void)0;
7033 }
7034 var1 = var2;
7035 }
7036 if (var1){
7037 {
7038 { /* Inline parser_nodes#ANode#parent= (var_node,self) on <var_node:nullable TKwredef(TKwredef)> */
7039 var_node->attrs[COLOR_parser_nodes__ANode___parent].val = self; /* _parent on <var_node:nullable TKwredef(TKwredef)> */
7040 RET_LABEL7:(void)0;
7041 }
7042 }
7043 } else {
7044 }
7045 RET_LABEL:;
7046 }
7047 /* method parser_prod#AAttrPropdef#n_kwredef= for (self: Object, nullable TKwredef) */
7048 void VIRTUAL_parser_prod__AAttrPropdef__n_kwredef_61d(val* self, val* p0) {
7049 parser_prod__AAttrPropdef__n_kwredef_61d(self, p0); /* Direct call parser_prod#AAttrPropdef#n_kwredef= on <self:Object(AAttrPropdef)>*/
7050 RET_LABEL:;
7051 }
7052 /* method parser_prod#AAttrPropdef#n_visibility= for (self: AAttrPropdef, nullable AVisibility) */
7053 void parser_prod__AAttrPropdef__n_visibility_61d(val* self, val* p0) {
7054 val* var_node /* var node: nullable AVisibility */;
7055 var_node = p0;
7056 self->attrs[COLOR_parser_nodes__APropdef___n_visibility].val = var_node; /* _n_visibility on <self:AAttrPropdef> */
7057 if (var_node == NULL) {
7058 PRINT_ERROR("Runtime error: %s", "Receiver is null");
7059 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 946);
7060 show_backtrace(1);
7061 } else {
7062 { /* Inline parser_nodes#ANode#parent= (var_node,self) on <var_node:nullable AVisibility> */
7063 if (unlikely(var_node == NULL)) {
7064 PRINT_ERROR("Runtime error: %s", "Receiver is null");
7065 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_nodes.nit", 38);
7066 show_backtrace(1);
7067 }
7068 var_node->attrs[COLOR_parser_nodes__ANode___parent].val = self; /* _parent on <var_node:nullable AVisibility> */
7069 RET_LABEL1:(void)0;
7070 }
7071 }
7072 RET_LABEL:;
7073 }
7074 /* method parser_prod#AAttrPropdef#n_visibility= for (self: Object, nullable AVisibility) */
7075 void VIRTUAL_parser_prod__AAttrPropdef__n_visibility_61d(val* self, val* p0) {
7076 parser_prod__AAttrPropdef__n_visibility_61d(self, p0); /* Direct call parser_prod#AAttrPropdef#n_visibility= on <self:Object(AAttrPropdef)>*/
7077 RET_LABEL:;
7078 }
7079 /* method parser_prod#AAttrPropdef#n_kwvar= for (self: AAttrPropdef, TKwvar) */
7080 void parser_prod__AAttrPropdef__n_kwvar_61d(val* self, val* p0) {
7081 val* var_node /* var node: TKwvar */;
7082 var_node = p0;
7083 self->attrs[COLOR_parser_nodes__AAttrPropdef___n_kwvar].val = var_node; /* _n_kwvar on <self:AAttrPropdef> */
7084 {
7085 { /* Inline parser_nodes#ANode#parent= (var_node,self) on <var_node:TKwvar> */
7086 var_node->attrs[COLOR_parser_nodes__ANode___parent].val = self; /* _parent on <var_node:TKwvar> */
7087 RET_LABEL1:(void)0;
7088 }
7089 }
7090 RET_LABEL:;
7091 }
7092 /* method parser_prod#AAttrPropdef#n_kwvar= for (self: Object, TKwvar) */
7093 void VIRTUAL_parser_prod__AAttrPropdef__n_kwvar_61d(val* self, val* p0) {
7094 parser_prod__AAttrPropdef__n_kwvar_61d(self, p0); /* Direct call parser_prod#AAttrPropdef#n_kwvar= on <self:Object(AAttrPropdef)>*/
7095 RET_LABEL:;
7096 }
7097 /* method parser_prod#AAttrPropdef#n_id= for (self: AAttrPropdef, nullable TAttrid) */
7098 void parser_prod__AAttrPropdef__n_id_61d(val* self, val* p0) {
7099 val* var_node /* var node: nullable TAttrid */;
7100 val* var /* : null */;
7101 short int var1 /* : Bool */;
7102 short int var2 /* : Bool */;
7103 val* var_other /* var other: nullable Object */;
7104 short int var4 /* : Bool */;
7105 short int var5 /* : Bool */;
7106 short int var6 /* : Bool */;
7107 var_node = p0;
7108 self->attrs[COLOR_parser_nodes__AAttrPropdef___n_id].val = var_node; /* _n_id on <self:AAttrPropdef> */
7109 var = NULL;
7110 if (var_node == NULL) {
7111 var1 = 0; /* is null */
7112 } else {
7113 var1 = 1; /* arg is null and recv is not */
7114 }
7115 if (0) {
7116 { /* Inline kernel#Object#!= (var_node,var) on <var_node:nullable TAttrid> */
7117 var_other = var;
7118 {
7119 var5 = ((short int (*)(val*, val*))(var_node->class->vft[COLOR_kernel__Object___61d_61d]))(var_node, var_other) /* == on <var_node:nullable TAttrid(TAttrid)>*/;
7120 var4 = var5;
7121 }
7122 var6 = !var4;
7123 var2 = var6;
7124 goto RET_LABEL3;
7125 RET_LABEL3:(void)0;
7126 }
7127 var1 = var2;
7128 }
7129 if (var1){
7130 {
7131 { /* Inline parser_nodes#ANode#parent= (var_node,self) on <var_node:nullable TAttrid(TAttrid)> */
7132 var_node->attrs[COLOR_parser_nodes__ANode___parent].val = self; /* _parent on <var_node:nullable TAttrid(TAttrid)> */
7133 RET_LABEL7:(void)0;
7134 }
7135 }
7136 } else {
7137 }
7138 RET_LABEL:;
7139 }
7140 /* method parser_prod#AAttrPropdef#n_id= for (self: Object, nullable TAttrid) */
7141 void VIRTUAL_parser_prod__AAttrPropdef__n_id_61d(val* self, val* p0) {
7142 parser_prod__AAttrPropdef__n_id_61d(self, p0); /* Direct call parser_prod#AAttrPropdef#n_id= on <self:Object(AAttrPropdef)>*/
7143 RET_LABEL:;
7144 }
7145 /* method parser_prod#AAttrPropdef#n_id2= for (self: AAttrPropdef, nullable TId) */
7146 void parser_prod__AAttrPropdef__n_id2_61d(val* self, val* p0) {
7147 val* var_node /* var node: nullable TId */;
7148 val* var /* : null */;
7149 short int var1 /* : Bool */;
7150 short int var2 /* : Bool */;
7151 val* var_other /* var other: nullable Object */;
7152 short int var4 /* : Bool */;
7153 short int var5 /* : Bool */;
7154 short int var6 /* : Bool */;
7155 var_node = p0;
7156 self->attrs[COLOR_parser_nodes__AAttrPropdef___n_id2].val = var_node; /* _n_id2 on <self:AAttrPropdef> */
7157 var = NULL;
7158 if (var_node == NULL) {
7159 var1 = 0; /* is null */
7160 } else {
7161 var1 = 1; /* arg is null and recv is not */
7162 }
7163 if (0) {
7164 { /* Inline kernel#Object#!= (var_node,var) on <var_node:nullable TId> */
7165 var_other = var;
7166 {
7167 var5 = ((short int (*)(val*, val*))(var_node->class->vft[COLOR_kernel__Object___61d_61d]))(var_node, var_other) /* == on <var_node:nullable TId(TId)>*/;
7168 var4 = var5;
7169 }
7170 var6 = !var4;
7171 var2 = var6;
7172 goto RET_LABEL3;
7173 RET_LABEL3:(void)0;
7174 }
7175 var1 = var2;
7176 }
7177 if (var1){
7178 {
7179 { /* Inline parser_nodes#ANode#parent= (var_node,self) on <var_node:nullable TId(TId)> */
7180 var_node->attrs[COLOR_parser_nodes__ANode___parent].val = self; /* _parent on <var_node:nullable TId(TId)> */
7181 RET_LABEL7:(void)0;
7182 }
7183 }
7184 } else {
7185 }
7186 RET_LABEL:;
7187 }
7188 /* method parser_prod#AAttrPropdef#n_id2= for (self: Object, nullable TId) */
7189 void VIRTUAL_parser_prod__AAttrPropdef__n_id2_61d(val* self, val* p0) {
7190 parser_prod__AAttrPropdef__n_id2_61d(self, p0); /* Direct call parser_prod#AAttrPropdef#n_id2= on <self:Object(AAttrPropdef)>*/
7191 RET_LABEL:;
7192 }
7193 /* method parser_prod#AAttrPropdef#n_type= for (self: AAttrPropdef, nullable AType) */
7194 void parser_prod__AAttrPropdef__n_type_61d(val* self, val* p0) {
7195 val* var_node /* var node: nullable AType */;
7196 val* var /* : null */;
7197 short int var1 /* : Bool */;
7198 short int var2 /* : Bool */;
7199 val* var_other /* var other: nullable Object */;
7200 short int var4 /* : Bool */;
7201 short int var5 /* : Bool */;
7202 short int var6 /* : Bool */;
7203 var_node = p0;
7204 self->attrs[COLOR_parser_nodes__AAttrPropdef___n_type].val = var_node; /* _n_type on <self:AAttrPropdef> */
7205 var = NULL;
7206 if (var_node == NULL) {
7207 var1 = 0; /* is null */
7208 } else {
7209 var1 = 1; /* arg is null and recv is not */
7210 }
7211 if (0) {
7212 { /* Inline kernel#Object#!= (var_node,var) on <var_node:nullable AType> */
7213 var_other = var;
7214 {
7215 var5 = ((short int (*)(val*, val*))(var_node->class->vft[COLOR_kernel__Object___61d_61d]))(var_node, var_other) /* == on <var_node:nullable AType(AType)>*/;
7216 var4 = var5;
7217 }
7218 var6 = !var4;
7219 var2 = var6;
7220 goto RET_LABEL3;
7221 RET_LABEL3:(void)0;
7222 }
7223 var1 = var2;
7224 }
7225 if (var1){
7226 {
7227 { /* Inline parser_nodes#ANode#parent= (var_node,self) on <var_node:nullable AType(AType)> */
7228 var_node->attrs[COLOR_parser_nodes__ANode___parent].val = self; /* _parent on <var_node:nullable AType(AType)> */
7229 RET_LABEL7:(void)0;
7230 }
7231 }
7232 } else {
7233 }
7234 RET_LABEL:;
7235 }
7236 /* method parser_prod#AAttrPropdef#n_type= for (self: Object, nullable AType) */
7237 void VIRTUAL_parser_prod__AAttrPropdef__n_type_61d(val* self, val* p0) {
7238 parser_prod__AAttrPropdef__n_type_61d(self, p0); /* Direct call parser_prod#AAttrPropdef#n_type= on <self:Object(AAttrPropdef)>*/
7239 RET_LABEL:;
7240 }
7241 /* method parser_prod#AAttrPropdef#n_annotations= for (self: AAttrPropdef, nullable AAnnotations) */
7242 void parser_prod__AAttrPropdef__n_annotations_61d(val* self, val* p0) {
7243 val* var_node /* var node: nullable AAnnotations */;
7244 val* var /* : null */;
7245 short int var1 /* : Bool */;
7246 short int var2 /* : Bool */;
7247 val* var_other /* var other: nullable Object */;
7248 short int var4 /* : Bool */;
7249 short int var5 /* : Bool */;
7250 short int var6 /* : Bool */;
7251 var_node = p0;
7252 self->attrs[COLOR_parser_nodes__Prod___n_annotations].val = var_node; /* _n_annotations on <self:AAttrPropdef> */
7253 var = NULL;
7254 if (var_node == NULL) {
7255 var1 = 0; /* is null */
7256 } else {
7257 var1 = 1; /* arg is null and recv is not */
7258 }
7259 if (0) {
7260 { /* Inline kernel#Object#!= (var_node,var) on <var_node:nullable AAnnotations> */
7261 var_other = var;
7262 {
7263 var5 = ((short int (*)(val*, val*))(var_node->class->vft[COLOR_kernel__Object___61d_61d]))(var_node, var_other) /* == on <var_node:nullable AAnnotations(AAnnotations)>*/;
7264 var4 = var5;
7265 }
7266 var6 = !var4;
7267 var2 = var6;
7268 goto RET_LABEL3;
7269 RET_LABEL3:(void)0;
7270 }
7271 var1 = var2;
7272 }
7273 if (var1){
7274 {
7275 { /* Inline parser_nodes#ANode#parent= (var_node,self) on <var_node:nullable AAnnotations(AAnnotations)> */
7276 var_node->attrs[COLOR_parser_nodes__ANode___parent].val = self; /* _parent on <var_node:nullable AAnnotations(AAnnotations)> */
7277 RET_LABEL7:(void)0;
7278 }
7279 }
7280 } else {
7281 }
7282 RET_LABEL:;
7283 }
7284 /* method parser_prod#AAttrPropdef#n_annotations= for (self: Object, nullable AAnnotations) */
7285 void VIRTUAL_parser_prod__AAttrPropdef__n_annotations_61d(val* self, val* p0) {
7286 parser_prod__AAttrPropdef__n_annotations_61d(self, p0); /* Direct call parser_prod#AAttrPropdef#n_annotations= on <self:Object(AAttrPropdef)>*/
7287 RET_LABEL:;
7288 }
7289 /* method parser_prod#AAttrPropdef#n_expr= for (self: AAttrPropdef, nullable AExpr) */
7290 void parser_prod__AAttrPropdef__n_expr_61d(val* self, val* p0) {
7291 val* var_node /* var node: nullable AExpr */;
7292 val* var /* : null */;
7293 short int var1 /* : Bool */;
7294 short int var2 /* : Bool */;
7295 val* var_other /* var other: nullable Object */;
7296 short int var4 /* : Bool */;
7297 short int var5 /* : Bool */;
7298 short int var6 /* : Bool */;
7299 var_node = p0;
7300 self->attrs[COLOR_parser_nodes__AAttrPropdef___n_expr].val = var_node; /* _n_expr on <self:AAttrPropdef> */
7301 var = NULL;
7302 if (var_node == NULL) {
7303 var1 = 0; /* is null */
7304 } else {
7305 var1 = 1; /* arg is null and recv is not */
7306 }
7307 if (0) {
7308 { /* Inline kernel#Object#!= (var_node,var) on <var_node:nullable AExpr> */
7309 var_other = var;
7310 {
7311 var5 = ((short int (*)(val*, val*))(var_node->class->vft[COLOR_kernel__Object___61d_61d]))(var_node, var_other) /* == on <var_node:nullable AExpr(AExpr)>*/;
7312 var4 = var5;
7313 }
7314 var6 = !var4;
7315 var2 = var6;
7316 goto RET_LABEL3;
7317 RET_LABEL3:(void)0;
7318 }
7319 var1 = var2;
7320 }
7321 if (var1){
7322 {
7323 { /* Inline parser_nodes#ANode#parent= (var_node,self) on <var_node:nullable AExpr(AExpr)> */
7324 var_node->attrs[COLOR_parser_nodes__ANode___parent].val = self; /* _parent on <var_node:nullable AExpr(AExpr)> */
7325 RET_LABEL7:(void)0;
7326 }
7327 }
7328 } else {
7329 }
7330 RET_LABEL:;
7331 }
7332 /* method parser_prod#AAttrPropdef#n_expr= for (self: Object, nullable AExpr) */
7333 void VIRTUAL_parser_prod__AAttrPropdef__n_expr_61d(val* self, val* p0) {
7334 parser_prod__AAttrPropdef__n_expr_61d(self, p0); /* Direct call parser_prod#AAttrPropdef#n_expr= on <self:Object(AAttrPropdef)>*/
7335 RET_LABEL:;
7336 }
7337 /* method parser_prod#AAttrPropdef#visit_all for (self: AAttrPropdef, Visitor) */
7338 void parser_prod__AAttrPropdef__visit_all(val* self, val* p0) {
7339 val* var_v /* var v: Visitor */;
7340 val* var /* : nullable ADoc */;
7341 val* var1 /* : nullable AAble */;
7342 val* var2 /* : nullable AAble */;
7343 val* var3 /* : nullable TKwredef */;
7344 val* var4 /* : nullable AVisibility */;
7345 val* var5 /* : TKwvar */;
7346 val* var6 /* : nullable TAttrid */;
7347 val* var7 /* : nullable TId */;
7348 val* var8 /* : nullable AType */;
7349 val* var9 /* : nullable AAnnotations */;
7350 val* var10 /* : nullable AExpr */;
7351 var_v = p0;
7352 var = self->attrs[COLOR_parser_nodes__APropdef___n_doc].val; /* _n_doc on <self:AAttrPropdef> */
7353 {
7354 parser_nodes__Visitor__enter_visit(var_v, var); /* Direct call parser_nodes#Visitor#enter_visit on <var_v:Visitor>*/
7355 }
7356 var1 = self->attrs[COLOR_parser_nodes__AAttrPropdef___n_readable].val; /* _n_readable on <self:AAttrPropdef> */
7357 {
7358 parser_nodes__Visitor__enter_visit(var_v, var1); /* Direct call parser_nodes#Visitor#enter_visit on <var_v:Visitor>*/
7359 }
7360 var2 = self->attrs[COLOR_parser_nodes__AAttrPropdef___n_writable].val; /* _n_writable on <self:AAttrPropdef> */
7361 {
7362 parser_nodes__Visitor__enter_visit(var_v, var2); /* Direct call parser_nodes#Visitor#enter_visit on <var_v:Visitor>*/
7363 }
7364 var3 = self->attrs[COLOR_parser_nodes__APropdef___n_kwredef].val; /* _n_kwredef on <self:AAttrPropdef> */
7365 {
7366 parser_nodes__Visitor__enter_visit(var_v, var3); /* Direct call parser_nodes#Visitor#enter_visit on <var_v:Visitor>*/
7367 }
7368 var4 = self->attrs[COLOR_parser_nodes__APropdef___n_visibility].val; /* _n_visibility on <self:AAttrPropdef> */
7369 {
7370 parser_nodes__Visitor__enter_visit(var_v, var4); /* Direct call parser_nodes#Visitor#enter_visit on <var_v:Visitor>*/
7371 }
7372 var5 = self->attrs[COLOR_parser_nodes__AAttrPropdef___n_kwvar].val; /* _n_kwvar on <self:AAttrPropdef> */
7373 if (unlikely(var5 == NULL)) {
7374 PRINT_ERROR("Runtime error: %s", "Uninitialized attribute _n_kwvar");
7375 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 987);
7376 show_backtrace(1);
7377 }
7378 {
7379 parser_nodes__Visitor__enter_visit(var_v, var5); /* Direct call parser_nodes#Visitor#enter_visit on <var_v:Visitor>*/
7380 }
7381 var6 = self->attrs[COLOR_parser_nodes__AAttrPropdef___n_id].val; /* _n_id on <self:AAttrPropdef> */
7382 {
7383 parser_nodes__Visitor__enter_visit(var_v, var6); /* Direct call parser_nodes#Visitor#enter_visit on <var_v:Visitor>*/
7384 }
7385 var7 = self->attrs[COLOR_parser_nodes__AAttrPropdef___n_id2].val; /* _n_id2 on <self:AAttrPropdef> */
7386 {
7387 parser_nodes__Visitor__enter_visit(var_v, var7); /* Direct call parser_nodes#Visitor#enter_visit on <var_v:Visitor>*/
7388 }
7389 var8 = self->attrs[COLOR_parser_nodes__AAttrPropdef___n_type].val; /* _n_type on <self:AAttrPropdef> */
7390 {
7391 parser_nodes__Visitor__enter_visit(var_v, var8); /* Direct call parser_nodes#Visitor#enter_visit on <var_v:Visitor>*/
7392 }
7393 var9 = self->attrs[COLOR_parser_nodes__Prod___n_annotations].val; /* _n_annotations on <self:AAttrPropdef> */
7394 {
7395 parser_nodes__Visitor__enter_visit(var_v, var9); /* Direct call parser_nodes#Visitor#enter_visit on <var_v:Visitor>*/
7396 }
7397 var10 = self->attrs[COLOR_parser_nodes__AAttrPropdef___n_expr].val; /* _n_expr on <self:AAttrPropdef> */
7398 {
7399 parser_nodes__Visitor__enter_visit(var_v, var10); /* Direct call parser_nodes#Visitor#enter_visit on <var_v:Visitor>*/
7400 }
7401 RET_LABEL:;
7402 }
7403 /* method parser_prod#AAttrPropdef#visit_all for (self: Object, Visitor) */
7404 void VIRTUAL_parser_prod__AAttrPropdef__visit_all(val* self, val* p0) {
7405 parser_prod__AAttrPropdef__visit_all(self, p0); /* Direct call parser_prod#AAttrPropdef#visit_all on <self:Object(AAttrPropdef)>*/
7406 RET_LABEL:;
7407 }
7408 /* method parser_prod#ADeferredMethPropdef#init_adeferredmethpropdef for (self: ADeferredMethPropdef, nullable ADoc, nullable TKwredef, nullable AVisibility, nullable TKwmeth, nullable AMethid, nullable ASignature, nullable AAnnotations) */
7409 void parser_prod__ADeferredMethPropdef__init_adeferredmethpropdef(val* self, val* p0, val* p1, val* p2, val* p3, val* p4, val* p5, val* p6) {
7410 val* var_n_doc /* var n_doc: nullable ADoc */;
7411 val* var_n_kwredef /* var n_kwredef: nullable TKwredef */;
7412 val* var_n_visibility /* var n_visibility: nullable AVisibility */;
7413 val* var_n_kwmeth /* var n_kwmeth: nullable TKwmeth */;
7414 val* var_n_methid /* var n_methid: nullable AMethid */;
7415 val* var_n_signature /* var n_signature: nullable ASignature */;
7416 val* var_n_annotations /* var n_annotations: nullable AAnnotations */;
7417 val* var /* : null */;
7418 short int var1 /* : Bool */;
7419 short int var2 /* : Bool */;
7420 val* var_other /* var other: nullable Object */;
7421 short int var4 /* : Bool */;
7422 short int var5 /* : Bool */;
7423 short int var6 /* : Bool */;
7424 val* var8 /* : null */;
7425 short int var9 /* : Bool */;
7426 short int var10 /* : Bool */;
7427 short int var12 /* : Bool */;
7428 short int var13 /* : Bool */;
7429 short int var14 /* : Bool */;
7430 val* var20 /* : null */;
7431 short int var21 /* : Bool */;
7432 short int var22 /* : Bool */;
7433 short int var24 /* : Bool */;
7434 short int var25 /* : Bool */;
7435 short int var26 /* : Bool */;
7436 var_n_doc = p0;
7437 var_n_kwredef = p1;
7438 var_n_visibility = p2;
7439 var_n_kwmeth = p3;
7440 var_n_methid = p4;
7441 var_n_signature = p5;
7442 var_n_annotations = p6;
7443 self->attrs[COLOR_parser_nodes__APropdef___n_doc].val = var_n_doc; /* _n_doc on <self:ADeferredMethPropdef> */
7444 var = NULL;
7445 if (var_n_doc == NULL) {
7446 var1 = 0; /* is null */
7447 } else {
7448 var1 = 1; /* arg is null and recv is not */
7449 }
7450 if (0) {
7451 { /* Inline kernel#Object#!= (var_n_doc,var) on <var_n_doc:nullable ADoc> */
7452 var_other = var;
7453 {
7454 var5 = ((short int (*)(val*, val*))(var_n_doc->class->vft[COLOR_kernel__Object___61d_61d]))(var_n_doc, var_other) /* == on <var_n_doc:nullable ADoc(ADoc)>*/;
7455 var4 = var5;
7456 }
7457 var6 = !var4;
7458 var2 = var6;
7459 goto RET_LABEL3;
7460 RET_LABEL3:(void)0;
7461 }
7462 var1 = var2;
7463 }
7464 if (var1){
7465 {
7466 { /* Inline parser_nodes#ANode#parent= (var_n_doc,self) on <var_n_doc:nullable ADoc(ADoc)> */
7467 var_n_doc->attrs[COLOR_parser_nodes__ANode___parent].val = self; /* _parent on <var_n_doc:nullable ADoc(ADoc)> */
7468 RET_LABEL7:(void)0;
7469 }
7470 }
7471 } else {
7472 }
7473 self->attrs[COLOR_parser_nodes__APropdef___n_kwredef].val = var_n_kwredef; /* _n_kwredef on <self:ADeferredMethPropdef> */
7474 var8 = NULL;
7475 if (var_n_kwredef == NULL) {
7476 var9 = 0; /* is null */
7477 } else {
7478 var9 = 1; /* arg is null and recv is not */
7479 }
7480 if (0) {
7481 { /* Inline kernel#Object#!= (var_n_kwredef,var8) on <var_n_kwredef:nullable TKwredef> */
7482 var_other = var8;
7483 {
7484 var13 = ((short int (*)(val*, val*))(var_n_kwredef->class->vft[COLOR_kernel__Object___61d_61d]))(var_n_kwredef, var_other) /* == on <var_n_kwredef:nullable TKwredef(TKwredef)>*/;
7485 var12 = var13;
7486 }
7487 var14 = !var12;
7488 var10 = var14;
7489 goto RET_LABEL11;
7490 RET_LABEL11:(void)0;
7491 }
7492 var9 = var10;
7493 }
7494 if (var9){
7495 {
7496 { /* Inline parser_nodes#ANode#parent= (var_n_kwredef,self) on <var_n_kwredef:nullable TKwredef(TKwredef)> */
7497 var_n_kwredef->attrs[COLOR_parser_nodes__ANode___parent].val = self; /* _parent on <var_n_kwredef:nullable TKwredef(TKwredef)> */
7498 RET_LABEL15:(void)0;
7499 }
7500 }
7501 } else {
7502 }
7503 if (unlikely(var_n_visibility == NULL)) {
7504 PRINT_ERROR("Runtime error: %s", "Cast failed");
7505 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 1091);
7506 show_backtrace(1);
7507 }
7508 self->attrs[COLOR_parser_nodes__APropdef___n_visibility].val = var_n_visibility; /* _n_visibility on <self:ADeferredMethPropdef> */
7509 if (var_n_visibility == NULL) {
7510 PRINT_ERROR("Runtime error: %s", "Receiver is null");
7511 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 1092);
7512 show_backtrace(1);
7513 } else {
7514 { /* Inline parser_nodes#ANode#parent= (var_n_visibility,self) on <var_n_visibility:nullable AVisibility> */
7515 if (unlikely(var_n_visibility == NULL)) {
7516 PRINT_ERROR("Runtime error: %s", "Receiver is null");
7517 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_nodes.nit", 38);
7518 show_backtrace(1);
7519 }
7520 var_n_visibility->attrs[COLOR_parser_nodes__ANode___parent].val = self; /* _parent on <var_n_visibility:nullable AVisibility> */
7521 RET_LABEL16:(void)0;
7522 }
7523 }
7524 if (unlikely(var_n_kwmeth == NULL)) {
7525 PRINT_ERROR("Runtime error: %s", "Cast failed");
7526 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 1093);
7527 show_backtrace(1);
7528 }
7529 self->attrs[COLOR_parser_nodes__AMethPropdef___n_kwmeth].val = var_n_kwmeth; /* _n_kwmeth on <self:ADeferredMethPropdef> */
7530 if (var_n_kwmeth == NULL) {
7531 PRINT_ERROR("Runtime error: %s", "Receiver is null");
7532 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 1094);
7533 show_backtrace(1);
7534 } else {
7535 { /* Inline parser_nodes#ANode#parent= (var_n_kwmeth,self) on <var_n_kwmeth:nullable TKwmeth> */
7536 if (unlikely(var_n_kwmeth == NULL)) {
7537 PRINT_ERROR("Runtime error: %s", "Receiver is null");
7538 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_nodes.nit", 38);
7539 show_backtrace(1);
7540 }
7541 var_n_kwmeth->attrs[COLOR_parser_nodes__ANode___parent].val = self; /* _parent on <var_n_kwmeth:nullable TKwmeth> */
7542 RET_LABEL17:(void)0;
7543 }
7544 }
7545 if (unlikely(var_n_methid == NULL)) {
7546 PRINT_ERROR("Runtime error: %s", "Cast failed");
7547 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 1095);
7548 show_backtrace(1);
7549 }
7550 self->attrs[COLOR_parser_nodes__AMethPropdef___n_methid].val = var_n_methid; /* _n_methid on <self:ADeferredMethPropdef> */
7551 if (var_n_methid == NULL) {
7552 PRINT_ERROR("Runtime error: %s", "Receiver is null");
7553 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 1096);
7554 show_backtrace(1);
7555 } else {
7556 { /* Inline parser_nodes#ANode#parent= (var_n_methid,self) on <var_n_methid:nullable AMethid> */
7557 if (unlikely(var_n_methid == NULL)) {
7558 PRINT_ERROR("Runtime error: %s", "Receiver is null");
7559 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_nodes.nit", 38);
7560 show_backtrace(1);
7561 }
7562 var_n_methid->attrs[COLOR_parser_nodes__ANode___parent].val = self; /* _parent on <var_n_methid:nullable AMethid> */
7563 RET_LABEL18:(void)0;
7564 }
7565 }
7566 if (unlikely(var_n_signature == NULL)) {
7567 PRINT_ERROR("Runtime error: %s", "Cast failed");
7568 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 1097);
7569 show_backtrace(1);
7570 }
7571 self->attrs[COLOR_parser_nodes__AMethPropdef___n_signature].val = var_n_signature; /* _n_signature on <self:ADeferredMethPropdef> */
7572 if (var_n_signature == NULL) {
7573 PRINT_ERROR("Runtime error: %s", "Receiver is null");
7574 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 1098);
7575 show_backtrace(1);
7576 } else {
7577 { /* Inline parser_nodes#ANode#parent= (var_n_signature,self) on <var_n_signature:nullable ASignature> */
7578 if (unlikely(var_n_signature == NULL)) {
7579 PRINT_ERROR("Runtime error: %s", "Receiver is null");
7580 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_nodes.nit", 38);
7581 show_backtrace(1);
7582 }
7583 var_n_signature->attrs[COLOR_parser_nodes__ANode___parent].val = self; /* _parent on <var_n_signature:nullable ASignature> */
7584 RET_LABEL19:(void)0;
7585 }
7586 }
7587 self->attrs[COLOR_parser_nodes__Prod___n_annotations].val = var_n_annotations; /* _n_annotations on <self:ADeferredMethPropdef> */
7588 var20 = NULL;
7589 if (var_n_annotations == NULL) {
7590 var21 = 0; /* is null */
7591 } else {
7592 var21 = 1; /* arg is null and recv is not */
7593 }
7594 if (0) {
7595 { /* Inline kernel#Object#!= (var_n_annotations,var20) on <var_n_annotations:nullable AAnnotations> */
7596 var_other = var20;
7597 {
7598 var25 = ((short int (*)(val*, val*))(var_n_annotations->class->vft[COLOR_kernel__Object___61d_61d]))(var_n_annotations, var_other) /* == on <var_n_annotations:nullable AAnnotations(AAnnotations)>*/;
7599 var24 = var25;
7600 }
7601 var26 = !var24;
7602 var22 = var26;
7603 goto RET_LABEL23;
7604 RET_LABEL23:(void)0;
7605 }
7606 var21 = var22;
7607 }
7608 if (var21){
7609 {
7610 { /* Inline parser_nodes#ANode#parent= (var_n_annotations,self) on <var_n_annotations:nullable AAnnotations(AAnnotations)> */
7611 var_n_annotations->attrs[COLOR_parser_nodes__ANode___parent].val = self; /* _parent on <var_n_annotations:nullable AAnnotations(AAnnotations)> */
7612 RET_LABEL27:(void)0;
7613 }
7614 }
7615 } else {
7616 }
7617 RET_LABEL:;
7618 }
7619 /* method parser_prod#ADeferredMethPropdef#init_adeferredmethpropdef for (self: Object, nullable ADoc, nullable TKwredef, nullable AVisibility, nullable TKwmeth, nullable AMethid, nullable ASignature, nullable AAnnotations) */
7620 void VIRTUAL_parser_prod__ADeferredMethPropdef__init_adeferredmethpropdef(val* self, val* p0, val* p1, val* p2, val* p3, val* p4, val* p5, val* p6) {
7621 parser_prod__ADeferredMethPropdef__init_adeferredmethpropdef(self, p0, p1, p2, p3, p4, p5, p6); /* Direct call parser_prod#ADeferredMethPropdef#init_adeferredmethpropdef on <self:Object(ADeferredMethPropdef)>*/
7622 RET_LABEL:;
7623 }
7624 /* method parser_prod#ADeferredMethPropdef#replace_child for (self: ADeferredMethPropdef, ANode, nullable ANode) */
7625 void parser_prod__ADeferredMethPropdef__replace_child(val* self, val* p0, val* p1) {
7626 val* var_old_child /* var old_child: ANode */;
7627 val* var_new_child /* var new_child: nullable ANode */;
7628 val* var /* : nullable ADoc */;
7629 short int var1 /* : Bool */;
7630 short int var2 /* : Bool */;
7631 val* var_other /* var other: nullable Object */;
7632 short int var4 /* : Bool */;
7633 short int var6 /* : Bool */;
7634 short int var7 /* : Bool */;
7635 int cltype;
7636 int idtype;
7637 const char* var_class_name;
7638 val* var8 /* : nullable TKwredef */;
7639 short int var9 /* : Bool */;
7640 short int var10 /* : Bool */;
7641 short int var12 /* : Bool */;
7642 short int var14 /* : Bool */;
7643 short int var15 /* : Bool */;
7644 int cltype16;
7645 int idtype17;
7646 const char* var_class_name18;
7647 val* var19 /* : nullable AVisibility */;
7648 short int var20 /* : Bool */;
7649 short int var21 /* : Bool */;
7650 short int var23 /* : Bool */;
7651 short int var25 /* : Bool */;
7652 short int var26 /* : Bool */;
7653 int cltype27;
7654 int idtype28;
7655 const char* var_class_name29;
7656 val* var30 /* : nullable TKwmeth */;
7657 short int var31 /* : Bool */;
7658 short int var32 /* : Bool */;
7659 short int var34 /* : Bool */;
7660 short int var36 /* : Bool */;
7661 short int var37 /* : Bool */;
7662 int cltype38;
7663 int idtype39;
7664 const char* var_class_name40;
7665 val* var41 /* : nullable AMethid */;
7666 short int var42 /* : Bool */;
7667 short int var43 /* : Bool */;
7668 short int var45 /* : Bool */;
7669 short int var47 /* : Bool */;
7670 short int var48 /* : Bool */;
7671 int cltype49;
7672 int idtype50;
7673 const char* var_class_name51;
7674 val* var52 /* : nullable ASignature */;
7675 short int var53 /* : Bool */;
7676 short int var54 /* : Bool */;
7677 short int var56 /* : Bool */;
7678 short int var58 /* : Bool */;
7679 short int var59 /* : Bool */;
7680 int cltype60;
7681 int idtype61;
7682 const char* var_class_name62;
7683 val* var63 /* : nullable AAnnotations */;
7684 short int var64 /* : Bool */;
7685 short int var65 /* : Bool */;
7686 short int var67 /* : Bool */;
7687 short int var69 /* : Bool */;
7688 short int var70 /* : Bool */;
7689 int cltype71;
7690 int idtype72;
7691 const char* var_class_name73;
7692 var_old_child = p0;
7693 var_new_child = p1;
7694 var = self->attrs[COLOR_parser_nodes__APropdef___n_doc].val; /* _n_doc on <self:ADeferredMethPropdef> */
7695 if (var == NULL) {
7696 var1 = 0; /* <var_old_child:ANode> cannot be null */
7697 } else {
7698 { /* Inline kernel#Object#== (var,var_old_child) on <var:nullable ADoc> */
7699 var_other = var_old_child;
7700 {
7701 { /* Inline kernel#Object#is_same_instance (var,var_other) on <var:nullable ADoc(ADoc)> */
7702 var6 = var == var_other;
7703 var4 = var6;
7704 goto RET_LABEL5;
7705 RET_LABEL5:(void)0;
7706 }
7707 }
7708 var2 = var4;
7709 goto RET_LABEL3;
7710 RET_LABEL3:(void)0;
7711 }
7712 var1 = var2;
7713 }
7714 if (var1){
7715 /* <var_new_child:nullable ANode> isa nullable ADoc */
7716 cltype = type_nullable_parser_nodes__ADoc.color;
7717 idtype = type_nullable_parser_nodes__ADoc.id;
7718 if(var_new_child == NULL) {
7719 var7 = 1;
7720 } else {
7721 if(cltype >= var_new_child->type->table_size) {
7722 var7 = 0;
7723 } else {
7724 var7 = var_new_child->type->type_table[cltype] == idtype;
7725 }
7726 }
7727 if (unlikely(!var7)) {
7728 var_class_name = var_new_child == NULL ? "null" : var_new_child->type->name;
7729 PRINT_ERROR("Runtime error: Cast failed. Expected `%s`, got `%s`", "nullable ADoc", var_class_name);
7730 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 1106);
7731 show_backtrace(1);
7732 }
7733 {
7734 parser_prod__ADeferredMethPropdef__n_doc_61d(self, var_new_child); /* Direct call parser_prod#ADeferredMethPropdef#n_doc= on <self:ADeferredMethPropdef>*/
7735 }
7736 goto RET_LABEL;
7737 } else {
7738 }
7739 var8 = self->attrs[COLOR_parser_nodes__APropdef___n_kwredef].val; /* _n_kwredef on <self:ADeferredMethPropdef> */
7740 if (var8 == NULL) {
7741 var9 = 0; /* <var_old_child:ANode> cannot be null */
7742 } else {
7743 { /* Inline kernel#Object#== (var8,var_old_child) on <var8:nullable TKwredef> */
7744 var_other = var_old_child;
7745 {
7746 { /* Inline kernel#Object#is_same_instance (var8,var_other) on <var8:nullable TKwredef(TKwredef)> */
7747 var14 = var8 == var_other;
7748 var12 = var14;
7749 goto RET_LABEL13;
7750 RET_LABEL13:(void)0;
7751 }
7752 }
7753 var10 = var12;
7754 goto RET_LABEL11;
7755 RET_LABEL11:(void)0;
7756 }
7757 var9 = var10;
7758 }
7759 if (var9){
7760 /* <var_new_child:nullable ANode> isa nullable TKwredef */
7761 cltype16 = type_nullable_parser_nodes__TKwredef.color;
7762 idtype17 = type_nullable_parser_nodes__TKwredef.id;
7763 if(var_new_child == NULL) {
7764 var15 = 1;
7765 } else {
7766 if(cltype16 >= var_new_child->type->table_size) {
7767 var15 = 0;
7768 } else {
7769 var15 = var_new_child->type->type_table[cltype16] == idtype17;
7770 }
7771 }
7772 if (unlikely(!var15)) {
7773 var_class_name18 = var_new_child == NULL ? "null" : var_new_child->type->name;
7774 PRINT_ERROR("Runtime error: Cast failed. Expected `%s`, got `%s`", "nullable TKwredef", var_class_name18);
7775 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 1110);
7776 show_backtrace(1);
7777 }
7778 {
7779 parser_prod__ADeferredMethPropdef__n_kwredef_61d(self, var_new_child); /* Direct call parser_prod#ADeferredMethPropdef#n_kwredef= on <self:ADeferredMethPropdef>*/
7780 }
7781 goto RET_LABEL;
7782 } else {
7783 }
7784 var19 = self->attrs[COLOR_parser_nodes__APropdef___n_visibility].val; /* _n_visibility on <self:ADeferredMethPropdef> */
7785 if (var19 == NULL) {
7786 var20 = 0; /* <var_old_child:ANode> cannot be null */
7787 } else {
7788 { /* Inline kernel#Object#== (var19,var_old_child) on <var19:nullable AVisibility> */
7789 var_other = var_old_child;
7790 {
7791 { /* Inline kernel#Object#is_same_instance (var19,var_other) on <var19:nullable AVisibility(AVisibility)> */
7792 var25 = var19 == var_other;
7793 var23 = var25;
7794 goto RET_LABEL24;
7795 RET_LABEL24:(void)0;
7796 }
7797 }
7798 var21 = var23;
7799 goto RET_LABEL22;
7800 RET_LABEL22:(void)0;
7801 }
7802 var20 = var21;
7803 }
7804 if (var20){
7805 /* <var_new_child:nullable ANode> isa AVisibility */
7806 cltype27 = type_parser_nodes__AVisibility.color;
7807 idtype28 = type_parser_nodes__AVisibility.id;
7808 if(var_new_child == NULL) {
7809 var26 = 0;
7810 } else {
7811 if(cltype27 >= var_new_child->type->table_size) {
7812 var26 = 0;
7813 } else {
7814 var26 = var_new_child->type->type_table[cltype27] == idtype28;
7815 }
7816 }
7817 if (unlikely(!var26)) {
7818 var_class_name29 = var_new_child == NULL ? "null" : var_new_child->type->name;
7819 PRINT_ERROR("Runtime error: Cast failed. Expected `%s`, got `%s`", "AVisibility", var_class_name29);
7820 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 1114);
7821 show_backtrace(1);
7822 }
7823 {
7824 parser_prod__ADeferredMethPropdef__n_visibility_61d(self, var_new_child); /* Direct call parser_prod#ADeferredMethPropdef#n_visibility= on <self:ADeferredMethPropdef>*/
7825 }
7826 goto RET_LABEL;
7827 } else {
7828 }
7829 var30 = self->attrs[COLOR_parser_nodes__AMethPropdef___n_kwmeth].val; /* _n_kwmeth on <self:ADeferredMethPropdef> */
7830 if (var30 == NULL) {
7831 var31 = 0; /* <var_old_child:ANode> cannot be null */
7832 } else {
7833 { /* Inline kernel#Object#== (var30,var_old_child) on <var30:nullable TKwmeth> */
7834 var_other = var_old_child;
7835 {
7836 { /* Inline kernel#Object#is_same_instance (var30,var_other) on <var30:nullable TKwmeth(TKwmeth)> */
7837 var36 = var30 == var_other;
7838 var34 = var36;
7839 goto RET_LABEL35;
7840 RET_LABEL35:(void)0;
7841 }
7842 }
7843 var32 = var34;
7844 goto RET_LABEL33;
7845 RET_LABEL33:(void)0;
7846 }
7847 var31 = var32;
7848 }
7849 if (var31){
7850 /* <var_new_child:nullable ANode> isa TKwmeth */
7851 cltype38 = type_parser_nodes__TKwmeth.color;
7852 idtype39 = type_parser_nodes__TKwmeth.id;
7853 if(var_new_child == NULL) {
7854 var37 = 0;
7855 } else {
7856 if(cltype38 >= var_new_child->type->table_size) {
7857 var37 = 0;
7858 } else {
7859 var37 = var_new_child->type->type_table[cltype38] == idtype39;
7860 }
7861 }
7862 if (unlikely(!var37)) {
7863 var_class_name40 = var_new_child == NULL ? "null" : var_new_child->type->name;
7864 PRINT_ERROR("Runtime error: Cast failed. Expected `%s`, got `%s`", "TKwmeth", var_class_name40);
7865 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 1118);
7866 show_backtrace(1);
7867 }
7868 {
7869 parser_prod__ADeferredMethPropdef__n_kwmeth_61d(self, var_new_child); /* Direct call parser_prod#ADeferredMethPropdef#n_kwmeth= on <self:ADeferredMethPropdef>*/
7870 }
7871 goto RET_LABEL;
7872 } else {
7873 }
7874 var41 = self->attrs[COLOR_parser_nodes__AMethPropdef___n_methid].val; /* _n_methid on <self:ADeferredMethPropdef> */
7875 if (var41 == NULL) {
7876 var42 = 0; /* <var_old_child:ANode> cannot be null */
7877 } else {
7878 { /* Inline kernel#Object#== (var41,var_old_child) on <var41:nullable AMethid> */
7879 var_other = var_old_child;
7880 {
7881 { /* Inline kernel#Object#is_same_instance (var41,var_other) on <var41:nullable AMethid(AMethid)> */
7882 var47 = var41 == var_other;
7883 var45 = var47;
7884 goto RET_LABEL46;
7885 RET_LABEL46:(void)0;
7886 }
7887 }
7888 var43 = var45;
7889 goto RET_LABEL44;
7890 RET_LABEL44:(void)0;
7891 }
7892 var42 = var43;
7893 }
7894 if (var42){
7895 /* <var_new_child:nullable ANode> isa AMethid */
7896 cltype49 = type_parser_nodes__AMethid.color;
7897 idtype50 = type_parser_nodes__AMethid.id;
7898 if(var_new_child == NULL) {
7899 var48 = 0;
7900 } else {
7901 if(cltype49 >= var_new_child->type->table_size) {
7902 var48 = 0;
7903 } else {
7904 var48 = var_new_child->type->type_table[cltype49] == idtype50;
7905 }
7906 }
7907 if (unlikely(!var48)) {
7908 var_class_name51 = var_new_child == NULL ? "null" : var_new_child->type->name;
7909 PRINT_ERROR("Runtime error: Cast failed. Expected `%s`, got `%s`", "AMethid", var_class_name51);
7910 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 1122);
7911 show_backtrace(1);
7912 }
7913 {
7914 parser_prod__ADeferredMethPropdef__n_methid_61d(self, var_new_child); /* Direct call parser_prod#ADeferredMethPropdef#n_methid= on <self:ADeferredMethPropdef>*/
7915 }
7916 goto RET_LABEL;
7917 } else {
7918 }
7919 var52 = self->attrs[COLOR_parser_nodes__AMethPropdef___n_signature].val; /* _n_signature on <self:ADeferredMethPropdef> */
7920 if (var52 == NULL) {
7921 var53 = 0; /* <var_old_child:ANode> cannot be null */
7922 } else {
7923 { /* Inline kernel#Object#== (var52,var_old_child) on <var52:nullable ASignature> */
7924 var_other = var_old_child;
7925 {
7926 { /* Inline kernel#Object#is_same_instance (var52,var_other) on <var52:nullable ASignature(ASignature)> */
7927 var58 = var52 == var_other;
7928 var56 = var58;
7929 goto RET_LABEL57;
7930 RET_LABEL57:(void)0;
7931 }
7932 }
7933 var54 = var56;
7934 goto RET_LABEL55;
7935 RET_LABEL55:(void)0;
7936 }
7937 var53 = var54;
7938 }
7939 if (var53){
7940 /* <var_new_child:nullable ANode> isa ASignature */
7941 cltype60 = type_parser_nodes__ASignature.color;
7942 idtype61 = type_parser_nodes__ASignature.id;
7943 if(var_new_child == NULL) {
7944 var59 = 0;
7945 } else {
7946 if(cltype60 >= var_new_child->type->table_size) {
7947 var59 = 0;
7948 } else {
7949 var59 = var_new_child->type->type_table[cltype60] == idtype61;
7950 }
7951 }
7952 if (unlikely(!var59)) {
7953 var_class_name62 = var_new_child == NULL ? "null" : var_new_child->type->name;
7954 PRINT_ERROR("Runtime error: Cast failed. Expected `%s`, got `%s`", "ASignature", var_class_name62);
7955 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 1126);
7956 show_backtrace(1);
7957 }
7958 {
7959 parser_prod__ADeferredMethPropdef__n_signature_61d(self, var_new_child); /* Direct call parser_prod#ADeferredMethPropdef#n_signature= on <self:ADeferredMethPropdef>*/
7960 }
7961 goto RET_LABEL;
7962 } else {
7963 }
7964 var63 = self->attrs[COLOR_parser_nodes__Prod___n_annotations].val; /* _n_annotations on <self:ADeferredMethPropdef> */
7965 if (var63 == NULL) {
7966 var64 = 0; /* <var_old_child:ANode> cannot be null */
7967 } else {
7968 { /* Inline kernel#Object#== (var63,var_old_child) on <var63:nullable AAnnotations> */
7969 var_other = var_old_child;
7970 {
7971 { /* Inline kernel#Object#is_same_instance (var63,var_other) on <var63:nullable AAnnotations(AAnnotations)> */
7972 var69 = var63 == var_other;
7973 var67 = var69;
7974 goto RET_LABEL68;
7975 RET_LABEL68:(void)0;
7976 }
7977 }
7978 var65 = var67;
7979 goto RET_LABEL66;
7980 RET_LABEL66:(void)0;
7981 }
7982 var64 = var65;
7983 }
7984 if (var64){
7985 /* <var_new_child:nullable ANode> isa nullable AAnnotations */
7986 cltype71 = type_nullable_parser_nodes__AAnnotations.color;
7987 idtype72 = type_nullable_parser_nodes__AAnnotations.id;
7988 if(var_new_child == NULL) {
7989 var70 = 1;
7990 } else {
7991 if(cltype71 >= var_new_child->type->table_size) {
7992 var70 = 0;
7993 } else {
7994 var70 = var_new_child->type->type_table[cltype71] == idtype72;
7995 }
7996 }
7997 if (unlikely(!var70)) {
7998 var_class_name73 = var_new_child == NULL ? "null" : var_new_child->type->name;
7999 PRINT_ERROR("Runtime error: Cast failed. Expected `%s`, got `%s`", "nullable AAnnotations", var_class_name73);
8000 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 1130);
8001 show_backtrace(1);
8002 }
8003 {
8004 parser_prod__ADeferredMethPropdef__n_annotations_61d(self, var_new_child); /* Direct call parser_prod#ADeferredMethPropdef#n_annotations= on <self:ADeferredMethPropdef>*/
8005 }
8006 goto RET_LABEL;
8007 } else {
8008 }
8009 RET_LABEL:;
8010 }
8011 /* method parser_prod#ADeferredMethPropdef#replace_child for (self: Object, ANode, nullable ANode) */
8012 void VIRTUAL_parser_prod__ADeferredMethPropdef__replace_child(val* self, val* p0, val* p1) {
8013 parser_prod__ADeferredMethPropdef__replace_child(self, p0, p1); /* Direct call parser_prod#ADeferredMethPropdef#replace_child on <self:Object(ADeferredMethPropdef)>*/
8014 RET_LABEL:;
8015 }
8016 /* method parser_prod#ADeferredMethPropdef#n_doc= for (self: ADeferredMethPropdef, nullable ADoc) */
8017 void parser_prod__ADeferredMethPropdef__n_doc_61d(val* self, val* p0) {
8018 val* var_node /* var node: nullable ADoc */;
8019 val* var /* : null */;
8020 short int var1 /* : Bool */;
8021 short int var2 /* : Bool */;
8022 val* var_other /* var other: nullable Object */;
8023 short int var4 /* : Bool */;
8024 short int var5 /* : Bool */;
8025 short int var6 /* : Bool */;
8026 var_node = p0;
8027 self->attrs[COLOR_parser_nodes__APropdef___n_doc].val = var_node; /* _n_doc on <self:ADeferredMethPropdef> */
8028 var = NULL;
8029 if (var_node == NULL) {
8030 var1 = 0; /* is null */
8031 } else {
8032 var1 = 1; /* arg is null and recv is not */
8033 }
8034 if (0) {
8035 { /* Inline kernel#Object#!= (var_node,var) on <var_node:nullable ADoc> */
8036 var_other = var;
8037 {
8038 var5 = ((short int (*)(val*, val*))(var_node->class->vft[COLOR_kernel__Object___61d_61d]))(var_node, var_other) /* == on <var_node:nullable ADoc(ADoc)>*/;
8039 var4 = var5;
8040 }
8041 var6 = !var4;
8042 var2 = var6;
8043 goto RET_LABEL3;
8044 RET_LABEL3:(void)0;
8045 }
8046 var1 = var2;
8047 }
8048 if (var1){
8049 {
8050 { /* Inline parser_nodes#ANode#parent= (var_node,self) on <var_node:nullable ADoc(ADoc)> */
8051 var_node->attrs[COLOR_parser_nodes__ANode___parent].val = self; /* _parent on <var_node:nullable ADoc(ADoc)> */
8052 RET_LABEL7:(void)0;
8053 }
8054 }
8055 } else {
8056 }
8057 RET_LABEL:;
8058 }
8059 /* method parser_prod#ADeferredMethPropdef#n_doc= for (self: Object, nullable ADoc) */
8060 void VIRTUAL_parser_prod__ADeferredMethPropdef__n_doc_61d(val* self, val* p0) {
8061 parser_prod__ADeferredMethPropdef__n_doc_61d(self, p0); /* Direct call parser_prod#ADeferredMethPropdef#n_doc= on <self:Object(ADeferredMethPropdef)>*/
8062 RET_LABEL:;
8063 }
8064 /* method parser_prod#ADeferredMethPropdef#n_kwredef= for (self: ADeferredMethPropdef, nullable TKwredef) */
8065 void parser_prod__ADeferredMethPropdef__n_kwredef_61d(val* self, val* p0) {
8066 val* var_node /* var node: nullable TKwredef */;
8067 val* var /* : null */;
8068 short int var1 /* : Bool */;
8069 short int var2 /* : Bool */;
8070 val* var_other /* var other: nullable Object */;
8071 short int var4 /* : Bool */;
8072 short int var5 /* : Bool */;
8073 short int var6 /* : Bool */;
8074 var_node = p0;
8075 self->attrs[COLOR_parser_nodes__APropdef___n_kwredef].val = var_node; /* _n_kwredef on <self:ADeferredMethPropdef> */
8076 var = NULL;
8077 if (var_node == NULL) {
8078 var1 = 0; /* is null */
8079 } else {
8080 var1 = 1; /* arg is null and recv is not */
8081 }
8082 if (0) {
8083 { /* Inline kernel#Object#!= (var_node,var) on <var_node:nullable TKwredef> */
8084 var_other = var;
8085 {
8086 var5 = ((short int (*)(val*, val*))(var_node->class->vft[COLOR_kernel__Object___61d_61d]))(var_node, var_other) /* == on <var_node:nullable TKwredef(TKwredef)>*/;
8087 var4 = var5;
8088 }
8089 var6 = !var4;
8090 var2 = var6;
8091 goto RET_LABEL3;
8092 RET_LABEL3:(void)0;
8093 }
8094 var1 = var2;
8095 }
8096 if (var1){
8097 {
8098 { /* Inline parser_nodes#ANode#parent= (var_node,self) on <var_node:nullable TKwredef(TKwredef)> */
8099 var_node->attrs[COLOR_parser_nodes__ANode___parent].val = self; /* _parent on <var_node:nullable TKwredef(TKwredef)> */
8100 RET_LABEL7:(void)0;
8101 }
8102 }
8103 } else {
8104 }
8105 RET_LABEL:;
8106 }
8107 /* method parser_prod#ADeferredMethPropdef#n_kwredef= for (self: Object, nullable TKwredef) */
8108 void VIRTUAL_parser_prod__ADeferredMethPropdef__n_kwredef_61d(val* self, val* p0) {
8109 parser_prod__ADeferredMethPropdef__n_kwredef_61d(self, p0); /* Direct call parser_prod#ADeferredMethPropdef#n_kwredef= on <self:Object(ADeferredMethPropdef)>*/
8110 RET_LABEL:;
8111 }
8112 /* method parser_prod#ADeferredMethPropdef#n_visibility= for (self: ADeferredMethPropdef, nullable AVisibility) */
8113 void parser_prod__ADeferredMethPropdef__n_visibility_61d(val* self, val* p0) {
8114 val* var_node /* var node: nullable AVisibility */;
8115 var_node = p0;
8116 self->attrs[COLOR_parser_nodes__APropdef___n_visibility].val = var_node; /* _n_visibility on <self:ADeferredMethPropdef> */
8117 if (var_node == NULL) {
8118 PRINT_ERROR("Runtime error: %s", "Receiver is null");
8119 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 1148);
8120 show_backtrace(1);
8121 } else {
8122 { /* Inline parser_nodes#ANode#parent= (var_node,self) on <var_node:nullable AVisibility> */
8123 if (unlikely(var_node == NULL)) {
8124 PRINT_ERROR("Runtime error: %s", "Receiver is null");
8125 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_nodes.nit", 38);
8126 show_backtrace(1);
8127 }
8128 var_node->attrs[COLOR_parser_nodes__ANode___parent].val = self; /* _parent on <var_node:nullable AVisibility> */
8129 RET_LABEL1:(void)0;
8130 }
8131 }
8132 RET_LABEL:;
8133 }
8134 /* method parser_prod#ADeferredMethPropdef#n_visibility= for (self: Object, nullable AVisibility) */
8135 void VIRTUAL_parser_prod__ADeferredMethPropdef__n_visibility_61d(val* self, val* p0) {
8136 parser_prod__ADeferredMethPropdef__n_visibility_61d(self, p0); /* Direct call parser_prod#ADeferredMethPropdef#n_visibility= on <self:Object(ADeferredMethPropdef)>*/
8137 RET_LABEL:;
8138 }
8139 /* method parser_prod#ADeferredMethPropdef#n_kwmeth= for (self: ADeferredMethPropdef, nullable TKwmeth) */
8140 void parser_prod__ADeferredMethPropdef__n_kwmeth_61d(val* self, val* p0) {
8141 val* var_node /* var node: nullable TKwmeth */;
8142 var_node = p0;
8143 self->attrs[COLOR_parser_nodes__AMethPropdef___n_kwmeth].val = var_node; /* _n_kwmeth on <self:ADeferredMethPropdef> */
8144 if (var_node == NULL) {
8145 PRINT_ERROR("Runtime error: %s", "Receiver is null");
8146 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 1153);
8147 show_backtrace(1);
8148 } else {
8149 { /* Inline parser_nodes#ANode#parent= (var_node,self) on <var_node:nullable TKwmeth> */
8150 if (unlikely(var_node == NULL)) {
8151 PRINT_ERROR("Runtime error: %s", "Receiver is null");
8152 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_nodes.nit", 38);
8153 show_backtrace(1);
8154 }
8155 var_node->attrs[COLOR_parser_nodes__ANode___parent].val = self; /* _parent on <var_node:nullable TKwmeth> */
8156 RET_LABEL1:(void)0;
8157 }
8158 }
8159 RET_LABEL:;
8160 }
8161 /* method parser_prod#ADeferredMethPropdef#n_kwmeth= for (self: Object, nullable TKwmeth) */
8162 void VIRTUAL_parser_prod__ADeferredMethPropdef__n_kwmeth_61d(val* self, val* p0) {
8163 parser_prod__ADeferredMethPropdef__n_kwmeth_61d(self, p0); /* Direct call parser_prod#ADeferredMethPropdef#n_kwmeth= on <self:Object(ADeferredMethPropdef)>*/
8164 RET_LABEL:;
8165 }
8166 /* method parser_prod#ADeferredMethPropdef#n_methid= for (self: ADeferredMethPropdef, nullable AMethid) */
8167 void parser_prod__ADeferredMethPropdef__n_methid_61d(val* self, val* p0) {
8168 val* var_node /* var node: nullable AMethid */;
8169 var_node = p0;
8170 self->attrs[COLOR_parser_nodes__AMethPropdef___n_methid].val = var_node; /* _n_methid on <self:ADeferredMethPropdef> */
8171 if (var_node == NULL) {
8172 PRINT_ERROR("Runtime error: %s", "Receiver is null");
8173 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 1158);
8174 show_backtrace(1);
8175 } else {
8176 { /* Inline parser_nodes#ANode#parent= (var_node,self) on <var_node:nullable AMethid> */
8177 if (unlikely(var_node == NULL)) {
8178 PRINT_ERROR("Runtime error: %s", "Receiver is null");
8179 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_nodes.nit", 38);
8180 show_backtrace(1);
8181 }
8182 var_node->attrs[COLOR_parser_nodes__ANode___parent].val = self; /* _parent on <var_node:nullable AMethid> */
8183 RET_LABEL1:(void)0;
8184 }
8185 }
8186 RET_LABEL:;
8187 }
8188 /* method parser_prod#ADeferredMethPropdef#n_methid= for (self: Object, nullable AMethid) */
8189 void VIRTUAL_parser_prod__ADeferredMethPropdef__n_methid_61d(val* self, val* p0) {
8190 parser_prod__ADeferredMethPropdef__n_methid_61d(self, p0); /* Direct call parser_prod#ADeferredMethPropdef#n_methid= on <self:Object(ADeferredMethPropdef)>*/
8191 RET_LABEL:;
8192 }
8193 /* method parser_prod#ADeferredMethPropdef#n_signature= for (self: ADeferredMethPropdef, nullable ASignature) */
8194 void parser_prod__ADeferredMethPropdef__n_signature_61d(val* self, val* p0) {
8195 val* var_node /* var node: nullable ASignature */;
8196 var_node = p0;
8197 self->attrs[COLOR_parser_nodes__AMethPropdef___n_signature].val = var_node; /* _n_signature on <self:ADeferredMethPropdef> */
8198 if (var_node == NULL) {
8199 PRINT_ERROR("Runtime error: %s", "Receiver is null");
8200 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 1163);
8201 show_backtrace(1);
8202 } else {
8203 { /* Inline parser_nodes#ANode#parent= (var_node,self) on <var_node:nullable ASignature> */
8204 if (unlikely(var_node == NULL)) {
8205 PRINT_ERROR("Runtime error: %s", "Receiver is null");
8206 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_nodes.nit", 38);
8207 show_backtrace(1);
8208 }
8209 var_node->attrs[COLOR_parser_nodes__ANode___parent].val = self; /* _parent on <var_node:nullable ASignature> */
8210 RET_LABEL1:(void)0;
8211 }
8212 }
8213 RET_LABEL:;
8214 }
8215 /* method parser_prod#ADeferredMethPropdef#n_signature= for (self: Object, nullable ASignature) */
8216 void VIRTUAL_parser_prod__ADeferredMethPropdef__n_signature_61d(val* self, val* p0) {
8217 parser_prod__ADeferredMethPropdef__n_signature_61d(self, p0); /* Direct call parser_prod#ADeferredMethPropdef#n_signature= on <self:Object(ADeferredMethPropdef)>*/
8218 RET_LABEL:;
8219 }
8220 /* method parser_prod#ADeferredMethPropdef#n_annotations= for (self: ADeferredMethPropdef, nullable AAnnotations) */
8221 void parser_prod__ADeferredMethPropdef__n_annotations_61d(val* self, val* p0) {
8222 val* var_node /* var node: nullable AAnnotations */;
8223 val* var /* : null */;
8224 short int var1 /* : Bool */;
8225 short int var2 /* : Bool */;
8226 val* var_other /* var other: nullable Object */;
8227 short int var4 /* : Bool */;
8228 short int var5 /* : Bool */;
8229 short int var6 /* : Bool */;
8230 var_node = p0;
8231 self->attrs[COLOR_parser_nodes__Prod___n_annotations].val = var_node; /* _n_annotations on <self:ADeferredMethPropdef> */
8232 var = NULL;
8233 if (var_node == NULL) {
8234 var1 = 0; /* is null */
8235 } else {
8236 var1 = 1; /* arg is null and recv is not */
8237 }
8238 if (0) {
8239 { /* Inline kernel#Object#!= (var_node,var) on <var_node:nullable AAnnotations> */
8240 var_other = var;
8241 {
8242 var5 = ((short int (*)(val*, val*))(var_node->class->vft[COLOR_kernel__Object___61d_61d]))(var_node, var_other) /* == on <var_node:nullable AAnnotations(AAnnotations)>*/;
8243 var4 = var5;
8244 }
8245 var6 = !var4;
8246 var2 = var6;
8247 goto RET_LABEL3;
8248 RET_LABEL3:(void)0;
8249 }
8250 var1 = var2;
8251 }
8252 if (var1){
8253 {
8254 { /* Inline parser_nodes#ANode#parent= (var_node,self) on <var_node:nullable AAnnotations(AAnnotations)> */
8255 var_node->attrs[COLOR_parser_nodes__ANode___parent].val = self; /* _parent on <var_node:nullable AAnnotations(AAnnotations)> */
8256 RET_LABEL7:(void)0;
8257 }
8258 }
8259 } else {
8260 }
8261 RET_LABEL:;
8262 }
8263 /* method parser_prod#ADeferredMethPropdef#n_annotations= for (self: Object, nullable AAnnotations) */
8264 void VIRTUAL_parser_prod__ADeferredMethPropdef__n_annotations_61d(val* self, val* p0) {
8265 parser_prod__ADeferredMethPropdef__n_annotations_61d(self, p0); /* Direct call parser_prod#ADeferredMethPropdef#n_annotations= on <self:Object(ADeferredMethPropdef)>*/
8266 RET_LABEL:;
8267 }
8268 /* method parser_prod#ADeferredMethPropdef#visit_all for (self: ADeferredMethPropdef, Visitor) */
8269 void parser_prod__ADeferredMethPropdef__visit_all(val* self, val* p0) {
8270 val* var_v /* var v: Visitor */;
8271 val* var /* : nullable ADoc */;
8272 val* var1 /* : nullable TKwredef */;
8273 val* var2 /* : nullable AVisibility */;
8274 val* var3 /* : nullable TKwmeth */;
8275 val* var4 /* : nullable AMethid */;
8276 val* var5 /* : nullable ASignature */;
8277 val* var6 /* : nullable AAnnotations */;
8278 var_v = p0;
8279 var = self->attrs[COLOR_parser_nodes__APropdef___n_doc].val; /* _n_doc on <self:ADeferredMethPropdef> */
8280 {
8281 parser_nodes__Visitor__enter_visit(var_v, var); /* Direct call parser_nodes#Visitor#enter_visit on <var_v:Visitor>*/
8282 }
8283 var1 = self->attrs[COLOR_parser_nodes__APropdef___n_kwredef].val; /* _n_kwredef on <self:ADeferredMethPropdef> */
8284 {
8285 parser_nodes__Visitor__enter_visit(var_v, var1); /* Direct call parser_nodes#Visitor#enter_visit on <var_v:Visitor>*/
8286 }
8287 var2 = self->attrs[COLOR_parser_nodes__APropdef___n_visibility].val; /* _n_visibility on <self:ADeferredMethPropdef> */
8288 {
8289 parser_nodes__Visitor__enter_visit(var_v, var2); /* Direct call parser_nodes#Visitor#enter_visit on <var_v:Visitor>*/
8290 }
8291 var3 = self->attrs[COLOR_parser_nodes__AMethPropdef___n_kwmeth].val; /* _n_kwmeth on <self:ADeferredMethPropdef> */
8292 {
8293 parser_nodes__Visitor__enter_visit(var_v, var3); /* Direct call parser_nodes#Visitor#enter_visit on <var_v:Visitor>*/
8294 }
8295 var4 = self->attrs[COLOR_parser_nodes__AMethPropdef___n_methid].val; /* _n_methid on <self:ADeferredMethPropdef> */
8296 {
8297 parser_nodes__Visitor__enter_visit(var_v, var4); /* Direct call parser_nodes#Visitor#enter_visit on <var_v:Visitor>*/
8298 }
8299 var5 = self->attrs[COLOR_parser_nodes__AMethPropdef___n_signature].val; /* _n_signature on <self:ADeferredMethPropdef> */
8300 {
8301 parser_nodes__Visitor__enter_visit(var_v, var5); /* Direct call parser_nodes#Visitor#enter_visit on <var_v:Visitor>*/
8302 }
8303 var6 = self->attrs[COLOR_parser_nodes__Prod___n_annotations].val; /* _n_annotations on <self:ADeferredMethPropdef> */
8304 {
8305 parser_nodes__Visitor__enter_visit(var_v, var6); /* Direct call parser_nodes#Visitor#enter_visit on <var_v:Visitor>*/
8306 }
8307 RET_LABEL:;
8308 }
8309 /* method parser_prod#ADeferredMethPropdef#visit_all for (self: Object, Visitor) */
8310 void VIRTUAL_parser_prod__ADeferredMethPropdef__visit_all(val* self, val* p0) {
8311 parser_prod__ADeferredMethPropdef__visit_all(self, p0); /* Direct call parser_prod#ADeferredMethPropdef#visit_all on <self:Object(ADeferredMethPropdef)>*/
8312 RET_LABEL:;
8313 }
8314 /* method parser_prod#AInternMethPropdef#init_ainternmethpropdef for (self: AInternMethPropdef, nullable ADoc, nullable TKwredef, nullable AVisibility, nullable TKwmeth, nullable AMethid, nullable ASignature) */
8315 void parser_prod__AInternMethPropdef__init_ainternmethpropdef(val* self, val* p0, val* p1, val* p2, val* p3, val* p4, val* p5) {
8316 val* var_n_doc /* var n_doc: nullable ADoc */;
8317 val* var_n_kwredef /* var n_kwredef: nullable TKwredef */;
8318 val* var_n_visibility /* var n_visibility: nullable AVisibility */;
8319 val* var_n_kwmeth /* var n_kwmeth: nullable TKwmeth */;
8320 val* var_n_methid /* var n_methid: nullable AMethid */;
8321 val* var_n_signature /* var n_signature: nullable ASignature */;
8322 val* var /* : null */;
8323 short int var1 /* : Bool */;
8324 short int var2 /* : Bool */;
8325 val* var_other /* var other: nullable Object */;
8326 short int var4 /* : Bool */;
8327 short int var5 /* : Bool */;
8328 short int var6 /* : Bool */;
8329 val* var8 /* : null */;
8330 short int var9 /* : Bool */;
8331 short int var10 /* : Bool */;
8332 short int var12 /* : Bool */;
8333 short int var13 /* : Bool */;
8334 short int var14 /* : Bool */;
8335 var_n_doc = p0;
8336 var_n_kwredef = p1;
8337 var_n_visibility = p2;
8338 var_n_kwmeth = p3;
8339 var_n_methid = p4;
8340 var_n_signature = p5;
8341 self->attrs[COLOR_parser_nodes__APropdef___n_doc].val = var_n_doc; /* _n_doc on <self:AInternMethPropdef> */
8342 var = NULL;
8343 if (var_n_doc == NULL) {
8344 var1 = 0; /* is null */
8345 } else {
8346 var1 = 1; /* arg is null and recv is not */
8347 }
8348 if (0) {
8349 { /* Inline kernel#Object#!= (var_n_doc,var) on <var_n_doc:nullable ADoc> */
8350 var_other = var;
8351 {
8352 var5 = ((short int (*)(val*, val*))(var_n_doc->class->vft[COLOR_kernel__Object___61d_61d]))(var_n_doc, var_other) /* == on <var_n_doc:nullable ADoc(ADoc)>*/;
8353 var4 = var5;
8354 }
8355 var6 = !var4;
8356 var2 = var6;
8357 goto RET_LABEL3;
8358 RET_LABEL3:(void)0;
8359 }
8360 var1 = var2;
8361 }
8362 if (var1){
8363 {
8364 { /* Inline parser_nodes#ANode#parent= (var_n_doc,self) on <var_n_doc:nullable ADoc(ADoc)> */
8365 var_n_doc->attrs[COLOR_parser_nodes__ANode___parent].val = self; /* _parent on <var_n_doc:nullable ADoc(ADoc)> */
8366 RET_LABEL7:(void)0;
8367 }
8368 }
8369 } else {
8370 }
8371 self->attrs[COLOR_parser_nodes__APropdef___n_kwredef].val = var_n_kwredef; /* _n_kwredef on <self:AInternMethPropdef> */
8372 var8 = NULL;
8373 if (var_n_kwredef == NULL) {
8374 var9 = 0; /* is null */
8375 } else {
8376 var9 = 1; /* arg is null and recv is not */
8377 }
8378 if (0) {
8379 { /* Inline kernel#Object#!= (var_n_kwredef,var8) on <var_n_kwredef:nullable TKwredef> */
8380 var_other = var8;
8381 {
8382 var13 = ((short int (*)(val*, val*))(var_n_kwredef->class->vft[COLOR_kernel__Object___61d_61d]))(var_n_kwredef, var_other) /* == on <var_n_kwredef:nullable TKwredef(TKwredef)>*/;
8383 var12 = var13;
8384 }
8385 var14 = !var12;
8386 var10 = var14;
8387 goto RET_LABEL11;
8388 RET_LABEL11:(void)0;
8389 }
8390 var9 = var10;
8391 }
8392 if (var9){
8393 {
8394 { /* Inline parser_nodes#ANode#parent= (var_n_kwredef,self) on <var_n_kwredef:nullable TKwredef(TKwredef)> */
8395 var_n_kwredef->attrs[COLOR_parser_nodes__ANode___parent].val = self; /* _parent on <var_n_kwredef:nullable TKwredef(TKwredef)> */
8396 RET_LABEL15:(void)0;
8397 }
8398 }
8399 } else {
8400 }
8401 if (unlikely(var_n_visibility == NULL)) {
8402 PRINT_ERROR("Runtime error: %s", "Cast failed");
8403 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 1197);
8404 show_backtrace(1);
8405 }
8406 self->attrs[COLOR_parser_nodes__APropdef___n_visibility].val = var_n_visibility; /* _n_visibility on <self:AInternMethPropdef> */
8407 if (var_n_visibility == NULL) {
8408 PRINT_ERROR("Runtime error: %s", "Receiver is null");
8409 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 1198);
8410 show_backtrace(1);
8411 } else {
8412 { /* Inline parser_nodes#ANode#parent= (var_n_visibility,self) on <var_n_visibility:nullable AVisibility> */
8413 if (unlikely(var_n_visibility == NULL)) {
8414 PRINT_ERROR("Runtime error: %s", "Receiver is null");
8415 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_nodes.nit", 38);
8416 show_backtrace(1);
8417 }
8418 var_n_visibility->attrs[COLOR_parser_nodes__ANode___parent].val = self; /* _parent on <var_n_visibility:nullable AVisibility> */
8419 RET_LABEL16:(void)0;
8420 }
8421 }
8422 if (unlikely(var_n_kwmeth == NULL)) {
8423 PRINT_ERROR("Runtime error: %s", "Cast failed");
8424 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 1199);
8425 show_backtrace(1);
8426 }
8427 self->attrs[COLOR_parser_nodes__AMethPropdef___n_kwmeth].val = var_n_kwmeth; /* _n_kwmeth on <self:AInternMethPropdef> */
8428 if (var_n_kwmeth == NULL) {
8429 PRINT_ERROR("Runtime error: %s", "Receiver is null");
8430 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 1200);
8431 show_backtrace(1);
8432 } else {
8433 { /* Inline parser_nodes#ANode#parent= (var_n_kwmeth,self) on <var_n_kwmeth:nullable TKwmeth> */
8434 if (unlikely(var_n_kwmeth == NULL)) {
8435 PRINT_ERROR("Runtime error: %s", "Receiver is null");
8436 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_nodes.nit", 38);
8437 show_backtrace(1);
8438 }
8439 var_n_kwmeth->attrs[COLOR_parser_nodes__ANode___parent].val = self; /* _parent on <var_n_kwmeth:nullable TKwmeth> */
8440 RET_LABEL17:(void)0;
8441 }
8442 }
8443 if (unlikely(var_n_methid == NULL)) {
8444 PRINT_ERROR("Runtime error: %s", "Cast failed");
8445 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 1201);
8446 show_backtrace(1);
8447 }
8448 self->attrs[COLOR_parser_nodes__AMethPropdef___n_methid].val = var_n_methid; /* _n_methid on <self:AInternMethPropdef> */
8449 if (var_n_methid == NULL) {
8450 PRINT_ERROR("Runtime error: %s", "Receiver is null");
8451 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 1202);
8452 show_backtrace(1);
8453 } else {
8454 { /* Inline parser_nodes#ANode#parent= (var_n_methid,self) on <var_n_methid:nullable AMethid> */
8455 if (unlikely(var_n_methid == NULL)) {
8456 PRINT_ERROR("Runtime error: %s", "Receiver is null");
8457 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_nodes.nit", 38);
8458 show_backtrace(1);
8459 }
8460 var_n_methid->attrs[COLOR_parser_nodes__ANode___parent].val = self; /* _parent on <var_n_methid:nullable AMethid> */
8461 RET_LABEL18:(void)0;
8462 }
8463 }
8464 if (unlikely(var_n_signature == NULL)) {
8465 PRINT_ERROR("Runtime error: %s", "Cast failed");
8466 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 1203);
8467 show_backtrace(1);
8468 }
8469 self->attrs[COLOR_parser_nodes__AMethPropdef___n_signature].val = var_n_signature; /* _n_signature on <self:AInternMethPropdef> */
8470 if (var_n_signature == NULL) {
8471 PRINT_ERROR("Runtime error: %s", "Receiver is null");
8472 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 1204);
8473 show_backtrace(1);
8474 } else {
8475 { /* Inline parser_nodes#ANode#parent= (var_n_signature,self) on <var_n_signature:nullable ASignature> */
8476 if (unlikely(var_n_signature == NULL)) {
8477 PRINT_ERROR("Runtime error: %s", "Receiver is null");
8478 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_nodes.nit", 38);
8479 show_backtrace(1);
8480 }
8481 var_n_signature->attrs[COLOR_parser_nodes__ANode___parent].val = self; /* _parent on <var_n_signature:nullable ASignature> */
8482 RET_LABEL19:(void)0;
8483 }
8484 }
8485 RET_LABEL:;
8486 }
8487 /* method parser_prod#AInternMethPropdef#init_ainternmethpropdef for (self: Object, nullable ADoc, nullable TKwredef, nullable AVisibility, nullable TKwmeth, nullable AMethid, nullable ASignature) */
8488 void VIRTUAL_parser_prod__AInternMethPropdef__init_ainternmethpropdef(val* self, val* p0, val* p1, val* p2, val* p3, val* p4, val* p5) {
8489 parser_prod__AInternMethPropdef__init_ainternmethpropdef(self, p0, p1, p2, p3, p4, p5); /* Direct call parser_prod#AInternMethPropdef#init_ainternmethpropdef on <self:Object(AInternMethPropdef)>*/
8490 RET_LABEL:;
8491 }
8492 /* method parser_prod#AInternMethPropdef#replace_child for (self: AInternMethPropdef, ANode, nullable ANode) */
8493 void parser_prod__AInternMethPropdef__replace_child(val* self, val* p0, val* p1) {
8494 val* var_old_child /* var old_child: ANode */;
8495 val* var_new_child /* var new_child: nullable ANode */;
8496 val* var /* : nullable ADoc */;
8497 short int var1 /* : Bool */;
8498 short int var2 /* : Bool */;
8499 val* var_other /* var other: nullable Object */;
8500 short int var4 /* : Bool */;
8501 short int var6 /* : Bool */;
8502 short int var7 /* : Bool */;
8503 int cltype;
8504 int idtype;
8505 const char* var_class_name;
8506 val* var8 /* : nullable TKwredef */;
8507 short int var9 /* : Bool */;
8508 short int var10 /* : Bool */;
8509 short int var12 /* : Bool */;
8510 short int var14 /* : Bool */;
8511 short int var15 /* : Bool */;
8512 int cltype16;
8513 int idtype17;
8514 const char* var_class_name18;
8515 val* var19 /* : nullable AVisibility */;
8516 short int var20 /* : Bool */;
8517 short int var21 /* : Bool */;
8518 short int var23 /* : Bool */;
8519 short int var25 /* : Bool */;
8520 short int var26 /* : Bool */;
8521 int cltype27;
8522 int idtype28;
8523 const char* var_class_name29;
8524 val* var30 /* : nullable TKwmeth */;
8525 short int var31 /* : Bool */;
8526 short int var32 /* : Bool */;
8527 short int var34 /* : Bool */;
8528 short int var36 /* : Bool */;
8529 short int var37 /* : Bool */;
8530 int cltype38;
8531 int idtype39;
8532 const char* var_class_name40;
8533 val* var41 /* : nullable AMethid */;
8534 short int var42 /* : Bool */;
8535 short int var43 /* : Bool */;
8536 short int var45 /* : Bool */;
8537 short int var47 /* : Bool */;
8538 short int var48 /* : Bool */;
8539 int cltype49;
8540 int idtype50;
8541 const char* var_class_name51;
8542 val* var52 /* : nullable ASignature */;
8543 short int var53 /* : Bool */;
8544 short int var54 /* : Bool */;
8545 short int var56 /* : Bool */;
8546 short int var58 /* : Bool */;
8547 short int var59 /* : Bool */;
8548 int cltype60;
8549 int idtype61;
8550 const char* var_class_name62;
8551 var_old_child = p0;
8552 var_new_child = p1;
8553 var = self->attrs[COLOR_parser_nodes__APropdef___n_doc].val; /* _n_doc on <self:AInternMethPropdef> */
8554 if (var == NULL) {
8555 var1 = 0; /* <var_old_child:ANode> cannot be null */
8556 } else {
8557 { /* Inline kernel#Object#== (var,var_old_child) on <var:nullable ADoc> */
8558 var_other = var_old_child;
8559 {
8560 { /* Inline kernel#Object#is_same_instance (var,var_other) on <var:nullable ADoc(ADoc)> */
8561 var6 = var == var_other;
8562 var4 = var6;
8563 goto RET_LABEL5;
8564 RET_LABEL5:(void)0;
8565 }
8566 }
8567 var2 = var4;
8568 goto RET_LABEL3;
8569 RET_LABEL3:(void)0;
8570 }
8571 var1 = var2;
8572 }
8573 if (var1){
8574 /* <var_new_child:nullable ANode> isa nullable ADoc */
8575 cltype = type_nullable_parser_nodes__ADoc.color;
8576 idtype = type_nullable_parser_nodes__ADoc.id;
8577 if(var_new_child == NULL) {
8578 var7 = 1;
8579 } else {
8580 if(cltype >= var_new_child->type->table_size) {
8581 var7 = 0;
8582 } else {
8583 var7 = var_new_child->type->type_table[cltype] == idtype;
8584 }
8585 }
8586 if (unlikely(!var7)) {
8587 var_class_name = var_new_child == NULL ? "null" : var_new_child->type->name;
8588 PRINT_ERROR("Runtime error: Cast failed. Expected `%s`, got `%s`", "nullable ADoc", var_class_name);
8589 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 1210);
8590 show_backtrace(1);
8591 }
8592 {
8593 ((void (*)(val*, val*))(self->class->vft[COLOR_parser_nodes__APropdef__n_doc_61d]))(self, var_new_child) /* n_doc= on <self:AInternMethPropdef>*/;
8594 }
8595 goto RET_LABEL;
8596 } else {
8597 }
8598 var8 = self->attrs[COLOR_parser_nodes__APropdef___n_kwredef].val; /* _n_kwredef on <self:AInternMethPropdef> */
8599 if (var8 == NULL) {
8600 var9 = 0; /* <var_old_child:ANode> cannot be null */
8601 } else {
8602 { /* Inline kernel#Object#== (var8,var_old_child) on <var8:nullable TKwredef> */
8603 var_other = var_old_child;
8604 {
8605 { /* Inline kernel#Object#is_same_instance (var8,var_other) on <var8:nullable TKwredef(TKwredef)> */
8606 var14 = var8 == var_other;
8607 var12 = var14;
8608 goto RET_LABEL13;
8609 RET_LABEL13:(void)0;
8610 }
8611 }
8612 var10 = var12;
8613 goto RET_LABEL11;
8614 RET_LABEL11:(void)0;
8615 }
8616 var9 = var10;
8617 }
8618 if (var9){
8619 /* <var_new_child:nullable ANode> isa nullable TKwredef */
8620 cltype16 = type_nullable_parser_nodes__TKwredef.color;
8621 idtype17 = type_nullable_parser_nodes__TKwredef.id;
8622 if(var_new_child == NULL) {
8623 var15 = 1;
8624 } else {
8625 if(cltype16 >= var_new_child->type->table_size) {
8626 var15 = 0;
8627 } else {
8628 var15 = var_new_child->type->type_table[cltype16] == idtype17;
8629 }
8630 }
8631 if (unlikely(!var15)) {
8632 var_class_name18 = var_new_child == NULL ? "null" : var_new_child->type->name;
8633 PRINT_ERROR("Runtime error: Cast failed. Expected `%s`, got `%s`", "nullable TKwredef", var_class_name18);
8634 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 1214);
8635 show_backtrace(1);
8636 }
8637 {
8638 ((void (*)(val*, val*))(self->class->vft[COLOR_parser_nodes__APropdef__n_kwredef_61d]))(self, var_new_child) /* n_kwredef= on <self:AInternMethPropdef>*/;
8639 }
8640 goto RET_LABEL;
8641 } else {
8642 }
8643 var19 = self->attrs[COLOR_parser_nodes__APropdef___n_visibility].val; /* _n_visibility on <self:AInternMethPropdef> */
8644 if (var19 == NULL) {
8645 var20 = 0; /* <var_old_child:ANode> cannot be null */
8646 } else {
8647 { /* Inline kernel#Object#== (var19,var_old_child) on <var19:nullable AVisibility> */
8648 var_other = var_old_child;
8649 {
8650 { /* Inline kernel#Object#is_same_instance (var19,var_other) on <var19:nullable AVisibility(AVisibility)> */
8651 var25 = var19 == var_other;
8652 var23 = var25;
8653 goto RET_LABEL24;
8654 RET_LABEL24:(void)0;
8655 }
8656 }
8657 var21 = var23;
8658 goto RET_LABEL22;
8659 RET_LABEL22:(void)0;
8660 }
8661 var20 = var21;
8662 }
8663 if (var20){
8664 /* <var_new_child:nullable ANode> isa AVisibility */
8665 cltype27 = type_parser_nodes__AVisibility.color;
8666 idtype28 = type_parser_nodes__AVisibility.id;
8667 if(var_new_child == NULL) {
8668 var26 = 0;
8669 } else {
8670 if(cltype27 >= var_new_child->type->table_size) {
8671 var26 = 0;
8672 } else {
8673 var26 = var_new_child->type->type_table[cltype27] == idtype28;
8674 }
8675 }
8676 if (unlikely(!var26)) {
8677 var_class_name29 = var_new_child == NULL ? "null" : var_new_child->type->name;
8678 PRINT_ERROR("Runtime error: Cast failed. Expected `%s`, got `%s`", "AVisibility", var_class_name29);
8679 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 1218);
8680 show_backtrace(1);
8681 }
8682 {
8683 ((void (*)(val*, val*))(self->class->vft[COLOR_parser_nodes__APropdef__n_visibility_61d]))(self, var_new_child) /* n_visibility= on <self:AInternMethPropdef>*/;
8684 }
8685 goto RET_LABEL;
8686 } else {
8687 }
8688 var30 = self->attrs[COLOR_parser_nodes__AMethPropdef___n_kwmeth].val; /* _n_kwmeth on <self:AInternMethPropdef> */
8689 if (var30 == NULL) {
8690 var31 = 0; /* <var_old_child:ANode> cannot be null */
8691 } else {
8692 { /* Inline kernel#Object#== (var30,var_old_child) on <var30:nullable TKwmeth> */
8693 var_other = var_old_child;
8694 {
8695 { /* Inline kernel#Object#is_same_instance (var30,var_other) on <var30:nullable TKwmeth(TKwmeth)> */
8696 var36 = var30 == var_other;
8697 var34 = var36;
8698 goto RET_LABEL35;
8699 RET_LABEL35:(void)0;
8700 }
8701 }
8702 var32 = var34;
8703 goto RET_LABEL33;
8704 RET_LABEL33:(void)0;
8705 }
8706 var31 = var32;
8707 }
8708 if (var31){
8709 /* <var_new_child:nullable ANode> isa TKwmeth */
8710 cltype38 = type_parser_nodes__TKwmeth.color;
8711 idtype39 = type_parser_nodes__TKwmeth.id;
8712 if(var_new_child == NULL) {
8713 var37 = 0;
8714 } else {
8715 if(cltype38 >= var_new_child->type->table_size) {
8716 var37 = 0;
8717 } else {
8718 var37 = var_new_child->type->type_table[cltype38] == idtype39;
8719 }
8720 }
8721 if (unlikely(!var37)) {
8722 var_class_name40 = var_new_child == NULL ? "null" : var_new_child->type->name;
8723 PRINT_ERROR("Runtime error: Cast failed. Expected `%s`, got `%s`", "TKwmeth", var_class_name40);
8724 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 1222);
8725 show_backtrace(1);
8726 }
8727 {
8728 parser_prod__AInternMethPropdef__n_kwmeth_61d(self, var_new_child); /* Direct call parser_prod#AInternMethPropdef#n_kwmeth= on <self:AInternMethPropdef>*/
8729 }
8730 goto RET_LABEL;
8731 } else {
8732 }
8733 var41 = self->attrs[COLOR_parser_nodes__AMethPropdef___n_methid].val; /* _n_methid on <self:AInternMethPropdef> */
8734 if (var41 == NULL) {
8735 var42 = 0; /* <var_old_child:ANode> cannot be null */
8736 } else {
8737 { /* Inline kernel#Object#== (var41,var_old_child) on <var41:nullable AMethid> */
8738 var_other = var_old_child;
8739 {
8740 { /* Inline kernel#Object#is_same_instance (var41,var_other) on <var41:nullable AMethid(AMethid)> */
8741 var47 = var41 == var_other;
8742 var45 = var47;
8743 goto RET_LABEL46;
8744 RET_LABEL46:(void)0;
8745 }
8746 }
8747 var43 = var45;
8748 goto RET_LABEL44;
8749 RET_LABEL44:(void)0;
8750 }
8751 var42 = var43;
8752 }
8753 if (var42){
8754 /* <var_new_child:nullable ANode> isa AMethid */
8755 cltype49 = type_parser_nodes__AMethid.color;
8756 idtype50 = type_parser_nodes__AMethid.id;
8757 if(var_new_child == NULL) {
8758 var48 = 0;
8759 } else {
8760 if(cltype49 >= var_new_child->type->table_size) {
8761 var48 = 0;
8762 } else {
8763 var48 = var_new_child->type->type_table[cltype49] == idtype50;
8764 }
8765 }
8766 if (unlikely(!var48)) {
8767 var_class_name51 = var_new_child == NULL ? "null" : var_new_child->type->name;
8768 PRINT_ERROR("Runtime error: Cast failed. Expected `%s`, got `%s`", "AMethid", var_class_name51);
8769 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 1226);
8770 show_backtrace(1);
8771 }
8772 {
8773 ((void (*)(val*, val*))(self->class->vft[COLOR_parser_nodes__AMethPropdef__n_methid_61d]))(self, var_new_child) /* n_methid= on <self:AInternMethPropdef>*/;
8774 }
8775 goto RET_LABEL;
8776 } else {
8777 }
8778 var52 = self->attrs[COLOR_parser_nodes__AMethPropdef___n_signature].val; /* _n_signature on <self:AInternMethPropdef> */
8779 if (var52 == NULL) {
8780 var53 = 0; /* <var_old_child:ANode> cannot be null */
8781 } else {
8782 { /* Inline kernel#Object#== (var52,var_old_child) on <var52:nullable ASignature> */
8783 var_other = var_old_child;
8784 {
8785 { /* Inline kernel#Object#is_same_instance (var52,var_other) on <var52:nullable ASignature(ASignature)> */
8786 var58 = var52 == var_other;
8787 var56 = var58;
8788 goto RET_LABEL57;
8789 RET_LABEL57:(void)0;
8790 }
8791 }
8792 var54 = var56;
8793 goto RET_LABEL55;
8794 RET_LABEL55:(void)0;
8795 }
8796 var53 = var54;
8797 }
8798 if (var53){
8799 /* <var_new_child:nullable ANode> isa ASignature */
8800 cltype60 = type_parser_nodes__ASignature.color;
8801 idtype61 = type_parser_nodes__ASignature.id;
8802 if(var_new_child == NULL) {
8803 var59 = 0;
8804 } else {
8805 if(cltype60 >= var_new_child->type->table_size) {
8806 var59 = 0;
8807 } else {
8808 var59 = var_new_child->type->type_table[cltype60] == idtype61;
8809 }
8810 }
8811 if (unlikely(!var59)) {
8812 var_class_name62 = var_new_child == NULL ? "null" : var_new_child->type->name;
8813 PRINT_ERROR("Runtime error: Cast failed. Expected `%s`, got `%s`", "ASignature", var_class_name62);
8814 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 1230);
8815 show_backtrace(1);
8816 }
8817 {
8818 ((void (*)(val*, val*))(self->class->vft[COLOR_parser_nodes__AMethPropdef__n_signature_61d]))(self, var_new_child) /* n_signature= on <self:AInternMethPropdef>*/;
8819 }
8820 goto RET_LABEL;
8821 } else {
8822 }
8823 RET_LABEL:;
8824 }
8825 /* method parser_prod#AInternMethPropdef#replace_child for (self: Object, ANode, nullable ANode) */
8826 void VIRTUAL_parser_prod__AInternMethPropdef__replace_child(val* self, val* p0, val* p1) {
8827 parser_prod__AInternMethPropdef__replace_child(self, p0, p1); /* Direct call parser_prod#AInternMethPropdef#replace_child on <self:Object(AInternMethPropdef)>*/
8828 RET_LABEL:;
8829 }
8830 /* method parser_prod#AInternMethPropdef#n_doc= for (self: AInternMethPropdef, nullable ADoc) */
8831 void parser_prod__AInternMethPropdef__n_doc_61d(val* self, val* p0) {
8832 val* var_node /* var node: nullable ADoc */;
8833 val* var /* : null */;
8834 short int var1 /* : Bool */;
8835 short int var2 /* : Bool */;
8836 val* var_other /* var other: nullable Object */;
8837 short int var4 /* : Bool */;
8838 short int var5 /* : Bool */;
8839 short int var6 /* : Bool */;
8840 var_node = p0;
8841 self->attrs[COLOR_parser_nodes__APropdef___n_doc].val = var_node; /* _n_doc on <self:AInternMethPropdef> */
8842 var = NULL;
8843 if (var_node == NULL) {
8844 var1 = 0; /* is null */
8845 } else {
8846 var1 = 1; /* arg is null and recv is not */
8847 }
8848 if (0) {
8849 { /* Inline kernel#Object#!= (var_node,var) on <var_node:nullable ADoc> */
8850 var_other = var;
8851 {
8852 var5 = ((short int (*)(val*, val*))(var_node->class->vft[COLOR_kernel__Object___61d_61d]))(var_node, var_other) /* == on <var_node:nullable ADoc(ADoc)>*/;
8853 var4 = var5;
8854 }
8855 var6 = !var4;
8856 var2 = var6;
8857 goto RET_LABEL3;
8858 RET_LABEL3:(void)0;
8859 }
8860 var1 = var2;
8861 }
8862 if (var1){
8863 {
8864 { /* Inline parser_nodes#ANode#parent= (var_node,self) on <var_node:nullable ADoc(ADoc)> */
8865 var_node->attrs[COLOR_parser_nodes__ANode___parent].val = self; /* _parent on <var_node:nullable ADoc(ADoc)> */
8866 RET_LABEL7:(void)0;
8867 }
8868 }
8869 } else {
8870 }
8871 RET_LABEL:;
8872 }
8873 /* method parser_prod#AInternMethPropdef#n_doc= for (self: Object, nullable ADoc) */
8874 void VIRTUAL_parser_prod__AInternMethPropdef__n_doc_61d(val* self, val* p0) {
8875 parser_prod__AInternMethPropdef__n_doc_61d(self, p0); /* Direct call parser_prod#AInternMethPropdef#n_doc= on <self:Object(AInternMethPropdef)>*/
8876 RET_LABEL:;
8877 }
8878 /* method parser_prod#AInternMethPropdef#n_kwredef= for (self: AInternMethPropdef, nullable TKwredef) */
8879 void parser_prod__AInternMethPropdef__n_kwredef_61d(val* self, val* p0) {
8880 val* var_node /* var node: nullable TKwredef */;
8881 val* var /* : null */;
8882 short int var1 /* : Bool */;
8883 short int var2 /* : Bool */;
8884 val* var_other /* var other: nullable Object */;
8885 short int var4 /* : Bool */;
8886 short int var5 /* : Bool */;
8887 short int var6 /* : Bool */;
8888 var_node = p0;
8889 self->attrs[COLOR_parser_nodes__APropdef___n_kwredef].val = var_node; /* _n_kwredef on <self:AInternMethPropdef> */
8890 var = NULL;
8891 if (var_node == NULL) {
8892 var1 = 0; /* is null */
8893 } else {
8894 var1 = 1; /* arg is null and recv is not */
8895 }
8896 if (0) {
8897 { /* Inline kernel#Object#!= (var_node,var) on <var_node:nullable TKwredef> */
8898 var_other = var;
8899 {
8900 var5 = ((short int (*)(val*, val*))(var_node->class->vft[COLOR_kernel__Object___61d_61d]))(var_node, var_other) /* == on <var_node:nullable TKwredef(TKwredef)>*/;
8901 var4 = var5;
8902 }
8903 var6 = !var4;
8904 var2 = var6;
8905 goto RET_LABEL3;
8906 RET_LABEL3:(void)0;
8907 }
8908 var1 = var2;
8909 }
8910 if (var1){
8911 {
8912 { /* Inline parser_nodes#ANode#parent= (var_node,self) on <var_node:nullable TKwredef(TKwredef)> */
8913 var_node->attrs[COLOR_parser_nodes__ANode___parent].val = self; /* _parent on <var_node:nullable TKwredef(TKwredef)> */
8914 RET_LABEL7:(void)0;
8915 }
8916 }
8917 } else {
8918 }
8919 RET_LABEL:;
8920 }
8921 /* method parser_prod#AInternMethPropdef#n_kwredef= for (self: Object, nullable TKwredef) */
8922 void VIRTUAL_parser_prod__AInternMethPropdef__n_kwredef_61d(val* self, val* p0) {
8923 parser_prod__AInternMethPropdef__n_kwredef_61d(self, p0); /* Direct call parser_prod#AInternMethPropdef#n_kwredef= on <self:Object(AInternMethPropdef)>*/
8924 RET_LABEL:;
8925 }
8926 /* method parser_prod#AInternMethPropdef#n_visibility= for (self: AInternMethPropdef, nullable AVisibility) */
8927 void parser_prod__AInternMethPropdef__n_visibility_61d(val* self, val* p0) {
8928 val* var_node /* var node: nullable AVisibility */;
8929 var_node = p0;
8930 self->attrs[COLOR_parser_nodes__APropdef___n_visibility].val = var_node; /* _n_visibility on <self:AInternMethPropdef> */
8931 if (var_node == NULL) {
8932 PRINT_ERROR("Runtime error: %s", "Receiver is null");
8933 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 1248);
8934 show_backtrace(1);
8935 } else {
8936 { /* Inline parser_nodes#ANode#parent= (var_node,self) on <var_node:nullable AVisibility> */
8937 if (unlikely(var_node == NULL)) {
8938 PRINT_ERROR("Runtime error: %s", "Receiver is null");
8939 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_nodes.nit", 38);
8940 show_backtrace(1);
8941 }
8942 var_node->attrs[COLOR_parser_nodes__ANode___parent].val = self; /* _parent on <var_node:nullable AVisibility> */
8943 RET_LABEL1:(void)0;
8944 }
8945 }
8946 RET_LABEL:;
8947 }
8948 /* method parser_prod#AInternMethPropdef#n_visibility= for (self: Object, nullable AVisibility) */
8949 void VIRTUAL_parser_prod__AInternMethPropdef__n_visibility_61d(val* self, val* p0) {
8950 parser_prod__AInternMethPropdef__n_visibility_61d(self, p0); /* Direct call parser_prod#AInternMethPropdef#n_visibility= on <self:Object(AInternMethPropdef)>*/
8951 RET_LABEL:;
8952 }
8953 /* method parser_prod#AInternMethPropdef#n_kwmeth= for (self: AInternMethPropdef, nullable TKwmeth) */
8954 void parser_prod__AInternMethPropdef__n_kwmeth_61d(val* self, val* p0) {
8955 val* var_node /* var node: nullable TKwmeth */;
8956 var_node = p0;
8957 self->attrs[COLOR_parser_nodes__AMethPropdef___n_kwmeth].val = var_node; /* _n_kwmeth on <self:AInternMethPropdef> */
8958 if (var_node == NULL) {
8959 PRINT_ERROR("Runtime error: %s", "Receiver is null");
8960 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 1253);
8961 show_backtrace(1);
8962 } else {
8963 { /* Inline parser_nodes#ANode#parent= (var_node,self) on <var_node:nullable TKwmeth> */
8964 if (unlikely(var_node == NULL)) {
8965 PRINT_ERROR("Runtime error: %s", "Receiver is null");
8966 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_nodes.nit", 38);
8967 show_backtrace(1);
8968 }
8969 var_node->attrs[COLOR_parser_nodes__ANode___parent].val = self; /* _parent on <var_node:nullable TKwmeth> */
8970 RET_LABEL1:(void)0;
8971 }
8972 }
8973 RET_LABEL:;
8974 }
8975 /* method parser_prod#AInternMethPropdef#n_kwmeth= for (self: Object, nullable TKwmeth) */
8976 void VIRTUAL_parser_prod__AInternMethPropdef__n_kwmeth_61d(val* self, val* p0) {
8977 parser_prod__AInternMethPropdef__n_kwmeth_61d(self, p0); /* Direct call parser_prod#AInternMethPropdef#n_kwmeth= on <self:Object(AInternMethPropdef)>*/
8978 RET_LABEL:;
8979 }
8980 /* method parser_prod#AInternMethPropdef#n_methid= for (self: AInternMethPropdef, nullable AMethid) */
8981 void parser_prod__AInternMethPropdef__n_methid_61d(val* self, val* p0) {
8982 val* var_node /* var node: nullable AMethid */;
8983 var_node = p0;
8984 self->attrs[COLOR_parser_nodes__AMethPropdef___n_methid].val = var_node; /* _n_methid on <self:AInternMethPropdef> */
8985 if (var_node == NULL) {
8986 PRINT_ERROR("Runtime error: %s", "Receiver is null");
8987 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 1258);
8988 show_backtrace(1);
8989 } else {
8990 { /* Inline parser_nodes#ANode#parent= (var_node,self) on <var_node:nullable AMethid> */
8991 if (unlikely(var_node == NULL)) {
8992 PRINT_ERROR("Runtime error: %s", "Receiver is null");
8993 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_nodes.nit", 38);
8994 show_backtrace(1);
8995 }
8996 var_node->attrs[COLOR_parser_nodes__ANode___parent].val = self; /* _parent on <var_node:nullable AMethid> */
8997 RET_LABEL1:(void)0;
8998 }
8999 }
9000 RET_LABEL:;
9001 }
9002 /* method parser_prod#AInternMethPropdef#n_methid= for (self: Object, nullable AMethid) */
9003 void VIRTUAL_parser_prod__AInternMethPropdef__n_methid_61d(val* self, val* p0) {
9004 parser_prod__AInternMethPropdef__n_methid_61d(self, p0); /* Direct call parser_prod#AInternMethPropdef#n_methid= on <self:Object(AInternMethPropdef)>*/
9005 RET_LABEL:;
9006 }
9007 /* method parser_prod#AInternMethPropdef#n_signature= for (self: AInternMethPropdef, nullable ASignature) */
9008 void parser_prod__AInternMethPropdef__n_signature_61d(val* self, val* p0) {
9009 val* var_node /* var node: nullable ASignature */;
9010 var_node = p0;
9011 self->attrs[COLOR_parser_nodes__AMethPropdef___n_signature].val = var_node; /* _n_signature on <self:AInternMethPropdef> */
9012 if (var_node == NULL) {
9013 PRINT_ERROR("Runtime error: %s", "Receiver is null");
9014 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 1263);
9015 show_backtrace(1);
9016 } else {
9017 { /* Inline parser_nodes#ANode#parent= (var_node,self) on <var_node:nullable ASignature> */
9018 if (unlikely(var_node == NULL)) {
9019 PRINT_ERROR("Runtime error: %s", "Receiver is null");
9020 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_nodes.nit", 38);
9021 show_backtrace(1);
9022 }
9023 var_node->attrs[COLOR_parser_nodes__ANode___parent].val = self; /* _parent on <var_node:nullable ASignature> */
9024 RET_LABEL1:(void)0;
9025 }
9026 }
9027 RET_LABEL:;
9028 }
9029 /* method parser_prod#AInternMethPropdef#n_signature= for (self: Object, nullable ASignature) */
9030 void VIRTUAL_parser_prod__AInternMethPropdef__n_signature_61d(val* self, val* p0) {
9031 parser_prod__AInternMethPropdef__n_signature_61d(self, p0); /* Direct call parser_prod#AInternMethPropdef#n_signature= on <self:Object(AInternMethPropdef)>*/
9032 RET_LABEL:;
9033 }
9034 /* method parser_prod#AInternMethPropdef#visit_all for (self: AInternMethPropdef, Visitor) */
9035 void parser_prod__AInternMethPropdef__visit_all(val* self, val* p0) {
9036 val* var_v /* var v: Visitor */;
9037 val* var /* : nullable ADoc */;
9038 val* var1 /* : nullable TKwredef */;
9039 val* var2 /* : nullable AVisibility */;
9040 val* var3 /* : nullable TKwmeth */;
9041 val* var4 /* : nullable AMethid */;
9042 val* var5 /* : nullable ASignature */;
9043 var_v = p0;
9044 var = self->attrs[COLOR_parser_nodes__APropdef___n_doc].val; /* _n_doc on <self:AInternMethPropdef> */
9045 {
9046 parser_nodes__Visitor__enter_visit(var_v, var); /* Direct call parser_nodes#Visitor#enter_visit on <var_v:Visitor>*/
9047 }
9048 var1 = self->attrs[COLOR_parser_nodes__APropdef___n_kwredef].val; /* _n_kwredef on <self:AInternMethPropdef> */
9049 {
9050 parser_nodes__Visitor__enter_visit(var_v, var1); /* Direct call parser_nodes#Visitor#enter_visit on <var_v:Visitor>*/
9051 }
9052 var2 = self->attrs[COLOR_parser_nodes__APropdef___n_visibility].val; /* _n_visibility on <self:AInternMethPropdef> */
9053 {
9054 parser_nodes__Visitor__enter_visit(var_v, var2); /* Direct call parser_nodes#Visitor#enter_visit on <var_v:Visitor>*/
9055 }
9056 var3 = self->attrs[COLOR_parser_nodes__AMethPropdef___n_kwmeth].val; /* _n_kwmeth on <self:AInternMethPropdef> */
9057 {
9058 parser_nodes__Visitor__enter_visit(var_v, var3); /* Direct call parser_nodes#Visitor#enter_visit on <var_v:Visitor>*/
9059 }
9060 var4 = self->attrs[COLOR_parser_nodes__AMethPropdef___n_methid].val; /* _n_methid on <self:AInternMethPropdef> */
9061 {
9062 parser_nodes__Visitor__enter_visit(var_v, var4); /* Direct call parser_nodes#Visitor#enter_visit on <var_v:Visitor>*/
9063 }
9064 var5 = self->attrs[COLOR_parser_nodes__AMethPropdef___n_signature].val; /* _n_signature on <self:AInternMethPropdef> */
9065 {
9066 parser_nodes__Visitor__enter_visit(var_v, var5); /* Direct call parser_nodes#Visitor#enter_visit on <var_v:Visitor>*/
9067 }
9068 RET_LABEL:;
9069 }
9070 /* method parser_prod#AInternMethPropdef#visit_all for (self: Object, Visitor) */
9071 void VIRTUAL_parser_prod__AInternMethPropdef__visit_all(val* self, val* p0) {
9072 parser_prod__AInternMethPropdef__visit_all(self, p0); /* Direct call parser_prod#AInternMethPropdef#visit_all on <self:Object(AInternMethPropdef)>*/
9073 RET_LABEL:;
9074 }
9075 /* method parser_prod#AInternNewPropdef#init_ainternnewpropdef for (self: AInternNewPropdef, nullable ADoc, nullable TKwredef, nullable AVisibility, nullable TKwnew, nullable AMethid, nullable ASignature) */
9076 void parser_prod__AInternNewPropdef__init_ainternnewpropdef(val* self, val* p0, val* p1, val* p2, val* p3, val* p4, val* p5) {
9077 val* var_n_doc /* var n_doc: nullable ADoc */;
9078 val* var_n_kwredef /* var n_kwredef: nullable TKwredef */;
9079 val* var_n_visibility /* var n_visibility: nullable AVisibility */;
9080 val* var_n_kwnew /* var n_kwnew: nullable TKwnew */;
9081 val* var_n_methid /* var n_methid: nullable AMethid */;
9082 val* var_n_signature /* var n_signature: nullable ASignature */;
9083 val* var /* : null */;
9084 short int var1 /* : Bool */;
9085 short int var2 /* : Bool */;
9086 val* var_other /* var other: nullable Object */;
9087 short int var4 /* : Bool */;
9088 short int var5 /* : Bool */;
9089 short int var6 /* : Bool */;
9090 val* var8 /* : null */;
9091 short int var9 /* : Bool */;
9092 short int var10 /* : Bool */;
9093 short int var12 /* : Bool */;
9094 short int var13 /* : Bool */;
9095 short int var14 /* : Bool */;
9096 val* var18 /* : null */;
9097 short int var19 /* : Bool */;
9098 short int var20 /* : Bool */;
9099 short int var22 /* : Bool */;
9100 short int var23 /* : Bool */;
9101 short int var24 /* : Bool */;
9102 var_n_doc = p0;
9103 var_n_kwredef = p1;
9104 var_n_visibility = p2;
9105 var_n_kwnew = p3;
9106 var_n_methid = p4;
9107 var_n_signature = p5;
9108 self->attrs[COLOR_parser_nodes__APropdef___n_doc].val = var_n_doc; /* _n_doc on <self:AInternNewPropdef> */
9109 var = NULL;
9110 if (var_n_doc == NULL) {
9111 var1 = 0; /* is null */
9112 } else {
9113 var1 = 1; /* arg is null and recv is not */
9114 }
9115 if (0) {
9116 { /* Inline kernel#Object#!= (var_n_doc,var) on <var_n_doc:nullable ADoc> */
9117 var_other = var;
9118 {
9119 var5 = ((short int (*)(val*, val*))(var_n_doc->class->vft[COLOR_kernel__Object___61d_61d]))(var_n_doc, var_other) /* == on <var_n_doc:nullable ADoc(ADoc)>*/;
9120 var4 = var5;
9121 }
9122 var6 = !var4;
9123 var2 = var6;
9124 goto RET_LABEL3;
9125 RET_LABEL3:(void)0;
9126 }
9127 var1 = var2;
9128 }
9129 if (var1){
9130 {
9131 { /* Inline parser_nodes#ANode#parent= (var_n_doc,self) on <var_n_doc:nullable ADoc(ADoc)> */
9132 var_n_doc->attrs[COLOR_parser_nodes__ANode___parent].val = self; /* _parent on <var_n_doc:nullable ADoc(ADoc)> */
9133 RET_LABEL7:(void)0;
9134 }
9135 }
9136 } else {
9137 }
9138 self->attrs[COLOR_parser_nodes__APropdef___n_kwredef].val = var_n_kwredef; /* _n_kwredef on <self:AInternNewPropdef> */
9139 var8 = NULL;
9140 if (var_n_kwredef == NULL) {
9141 var9 = 0; /* is null */
9142 } else {
9143 var9 = 1; /* arg is null and recv is not */
9144 }
9145 if (0) {
9146 { /* Inline kernel#Object#!= (var_n_kwredef,var8) on <var_n_kwredef:nullable TKwredef> */
9147 var_other = var8;
9148 {
9149 var13 = ((short int (*)(val*, val*))(var_n_kwredef->class->vft[COLOR_kernel__Object___61d_61d]))(var_n_kwredef, var_other) /* == on <var_n_kwredef:nullable TKwredef(TKwredef)>*/;
9150 var12 = var13;
9151 }
9152 var14 = !var12;
9153 var10 = var14;
9154 goto RET_LABEL11;
9155 RET_LABEL11:(void)0;
9156 }
9157 var9 = var10;
9158 }
9159 if (var9){
9160 {
9161 { /* Inline parser_nodes#ANode#parent= (var_n_kwredef,self) on <var_n_kwredef:nullable TKwredef(TKwredef)> */
9162 var_n_kwredef->attrs[COLOR_parser_nodes__ANode___parent].val = self; /* _parent on <var_n_kwredef:nullable TKwredef(TKwredef)> */
9163 RET_LABEL15:(void)0;
9164 }
9165 }
9166 } else {
9167 }
9168 if (unlikely(var_n_visibility == NULL)) {
9169 PRINT_ERROR("Runtime error: %s", "Cast failed");
9170 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 1291);
9171 show_backtrace(1);
9172 }
9173 self->attrs[COLOR_parser_nodes__APropdef___n_visibility].val = var_n_visibility; /* _n_visibility on <self:AInternNewPropdef> */
9174 if (var_n_visibility == NULL) {
9175 PRINT_ERROR("Runtime error: %s", "Receiver is null");
9176 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 1292);
9177 show_backtrace(1);
9178 } else {
9179 { /* Inline parser_nodes#ANode#parent= (var_n_visibility,self) on <var_n_visibility:nullable AVisibility> */
9180 if (unlikely(var_n_visibility == NULL)) {
9181 PRINT_ERROR("Runtime error: %s", "Receiver is null");
9182 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_nodes.nit", 38);
9183 show_backtrace(1);
9184 }
9185 var_n_visibility->attrs[COLOR_parser_nodes__ANode___parent].val = self; /* _parent on <var_n_visibility:nullable AVisibility> */
9186 RET_LABEL16:(void)0;
9187 }
9188 }
9189 if (unlikely(var_n_kwnew == NULL)) {
9190 PRINT_ERROR("Runtime error: %s", "Cast failed");
9191 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 1293);
9192 show_backtrace(1);
9193 }
9194 self->attrs[COLOR_parser_nodes__AMethPropdef___n_kwnew].val = var_n_kwnew; /* _n_kwnew on <self:AInternNewPropdef> */
9195 if (var_n_kwnew == NULL) {
9196 PRINT_ERROR("Runtime error: %s", "Receiver is null");
9197 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 1294);
9198 show_backtrace(1);
9199 } else {
9200 { /* Inline parser_nodes#ANode#parent= (var_n_kwnew,self) on <var_n_kwnew:nullable TKwnew> */
9201 if (unlikely(var_n_kwnew == NULL)) {
9202 PRINT_ERROR("Runtime error: %s", "Receiver is null");
9203 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_nodes.nit", 38);
9204 show_backtrace(1);
9205 }
9206 var_n_kwnew->attrs[COLOR_parser_nodes__ANode___parent].val = self; /* _parent on <var_n_kwnew:nullable TKwnew> */
9207 RET_LABEL17:(void)0;
9208 }
9209 }
9210 self->attrs[COLOR_parser_nodes__AMethPropdef___n_methid].val = var_n_methid; /* _n_methid on <self:AInternNewPropdef> */
9211 var18 = NULL;
9212 if (var_n_methid == NULL) {
9213 var19 = 0; /* is null */
9214 } else {
9215 var19 = 1; /* arg is null and recv is not */
9216 }
9217 if (0) {
9218 { /* Inline kernel#Object#!= (var_n_methid,var18) on <var_n_methid:nullable AMethid> */
9219 var_other = var18;
9220 {
9221 var23 = ((short int (*)(val*, val*))(var_n_methid->class->vft[COLOR_kernel__Object___61d_61d]))(var_n_methid, var_other) /* == on <var_n_methid:nullable AMethid(AMethid)>*/;
9222 var22 = var23;
9223 }
9224 var24 = !var22;
9225 var20 = var24;
9226 goto RET_LABEL21;
9227 RET_LABEL21:(void)0;
9228 }
9229 var19 = var20;
9230 }
9231 if (var19){
9232 {
9233 { /* Inline parser_nodes#ANode#parent= (var_n_methid,self) on <var_n_methid:nullable AMethid(AMethid)> */
9234 var_n_methid->attrs[COLOR_parser_nodes__ANode___parent].val = self; /* _parent on <var_n_methid:nullable AMethid(AMethid)> */
9235 RET_LABEL25:(void)0;
9236 }
9237 }
9238 } else {
9239 }
9240 if (unlikely(var_n_signature == NULL)) {
9241 PRINT_ERROR("Runtime error: %s", "Cast failed");
9242 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 1297);
9243 show_backtrace(1);
9244 }
9245 self->attrs[COLOR_parser_nodes__AMethPropdef___n_signature].val = var_n_signature; /* _n_signature on <self:AInternNewPropdef> */
9246 if (var_n_signature == NULL) {
9247 PRINT_ERROR("Runtime error: %s", "Receiver is null");
9248 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 1298);
9249 show_backtrace(1);
9250 } else {
9251 { /* Inline parser_nodes#ANode#parent= (var_n_signature,self) on <var_n_signature:nullable ASignature> */
9252 if (unlikely(var_n_signature == NULL)) {
9253 PRINT_ERROR("Runtime error: %s", "Receiver is null");
9254 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_nodes.nit", 38);
9255 show_backtrace(1);
9256 }
9257 var_n_signature->attrs[COLOR_parser_nodes__ANode___parent].val = self; /* _parent on <var_n_signature:nullable ASignature> */
9258 RET_LABEL26:(void)0;
9259 }
9260 }
9261 RET_LABEL:;
9262 }
9263 /* method parser_prod#AInternNewPropdef#init_ainternnewpropdef for (self: Object, nullable ADoc, nullable TKwredef, nullable AVisibility, nullable TKwnew, nullable AMethid, nullable ASignature) */
9264 void VIRTUAL_parser_prod__AInternNewPropdef__init_ainternnewpropdef(val* self, val* p0, val* p1, val* p2, val* p3, val* p4, val* p5) {
9265 parser_prod__AInternNewPropdef__init_ainternnewpropdef(self, p0, p1, p2, p3, p4, p5); /* Direct call parser_prod#AInternNewPropdef#init_ainternnewpropdef on <self:Object(AInternNewPropdef)>*/
9266 RET_LABEL:;
9267 }
9268 /* method parser_prod#AInternNewPropdef#replace_child for (self: AInternNewPropdef, ANode, nullable ANode) */
9269 void parser_prod__AInternNewPropdef__replace_child(val* self, val* p0, val* p1) {
9270 val* var_old_child /* var old_child: ANode */;
9271 val* var_new_child /* var new_child: nullable ANode */;
9272 val* var /* : nullable ADoc */;
9273 short int var1 /* : Bool */;
9274 short int var2 /* : Bool */;
9275 val* var_other /* var other: nullable Object */;
9276 short int var4 /* : Bool */;
9277 short int var6 /* : Bool */;
9278 short int var7 /* : Bool */;
9279 int cltype;
9280 int idtype;
9281 const char* var_class_name;
9282 val* var8 /* : nullable TKwredef */;
9283 short int var9 /* : Bool */;
9284 short int var10 /* : Bool */;
9285 short int var12 /* : Bool */;
9286 short int var14 /* : Bool */;
9287 short int var15 /* : Bool */;
9288 int cltype16;
9289 int idtype17;
9290 const char* var_class_name18;
9291 val* var19 /* : nullable AVisibility */;
9292 short int var20 /* : Bool */;
9293 short int var21 /* : Bool */;
9294 short int var23 /* : Bool */;
9295 short int var25 /* : Bool */;
9296 short int var26 /* : Bool */;
9297 int cltype27;
9298 int idtype28;
9299 const char* var_class_name29;
9300 val* var30 /* : nullable TKwnew */;
9301 short int var31 /* : Bool */;
9302 short int var32 /* : Bool */;
9303 short int var34 /* : Bool */;
9304 short int var36 /* : Bool */;
9305 short int var37 /* : Bool */;
9306 int cltype38;
9307 int idtype39;
9308 const char* var_class_name40;
9309 val* var41 /* : nullable AMethid */;
9310 short int var42 /* : Bool */;
9311 short int var43 /* : Bool */;
9312 short int var45 /* : Bool */;
9313 short int var47 /* : Bool */;
9314 short int var48 /* : Bool */;
9315 int cltype49;
9316 int idtype50;
9317 const char* var_class_name51;
9318 val* var52 /* : nullable ASignature */;
9319 short int var53 /* : Bool */;
9320 short int var54 /* : Bool */;
9321 short int var56 /* : Bool */;
9322 short int var58 /* : Bool */;
9323 short int var59 /* : Bool */;
9324 int cltype60;
9325 int idtype61;
9326 const char* var_class_name62;
9327 var_old_child = p0;
9328 var_new_child = p1;
9329 var = self->attrs[COLOR_parser_nodes__APropdef___n_doc].val; /* _n_doc on <self:AInternNewPropdef> */
9330 if (var == NULL) {
9331 var1 = 0; /* <var_old_child:ANode> cannot be null */
9332 } else {
9333 { /* Inline kernel#Object#== (var,var_old_child) on <var:nullable ADoc> */
9334 var_other = var_old_child;
9335 {
9336 { /* Inline kernel#Object#is_same_instance (var,var_other) on <var:nullable ADoc(ADoc)> */
9337 var6 = var == var_other;
9338 var4 = var6;
9339 goto RET_LABEL5;
9340 RET_LABEL5:(void)0;
9341 }
9342 }
9343 var2 = var4;
9344 goto RET_LABEL3;
9345 RET_LABEL3:(void)0;
9346 }
9347 var1 = var2;
9348 }
9349 if (var1){
9350 /* <var_new_child:nullable ANode> isa nullable ADoc */
9351 cltype = type_nullable_parser_nodes__ADoc.color;
9352 idtype = type_nullable_parser_nodes__ADoc.id;
9353 if(var_new_child == NULL) {
9354 var7 = 1;
9355 } else {
9356 if(cltype >= var_new_child->type->table_size) {
9357 var7 = 0;
9358 } else {
9359 var7 = var_new_child->type->type_table[cltype] == idtype;
9360 }
9361 }
9362 if (unlikely(!var7)) {
9363 var_class_name = var_new_child == NULL ? "null" : var_new_child->type->name;
9364 PRINT_ERROR("Runtime error: Cast failed. Expected `%s`, got `%s`", "nullable ADoc", var_class_name);
9365 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 1304);
9366 show_backtrace(1);
9367 }
9368 {
9369 parser_prod__AInternNewPropdef__n_doc_61d(self, var_new_child); /* Direct call parser_prod#AInternNewPropdef#n_doc= on <self:AInternNewPropdef>*/
9370 }
9371 goto RET_LABEL;
9372 } else {
9373 }
9374 var8 = self->attrs[COLOR_parser_nodes__APropdef___n_kwredef].val; /* _n_kwredef on <self:AInternNewPropdef> */
9375 if (var8 == NULL) {
9376 var9 = 0; /* <var_old_child:ANode> cannot be null */
9377 } else {
9378 { /* Inline kernel#Object#== (var8,var_old_child) on <var8:nullable TKwredef> */
9379 var_other = var_old_child;
9380 {
9381 { /* Inline kernel#Object#is_same_instance (var8,var_other) on <var8:nullable TKwredef(TKwredef)> */
9382 var14 = var8 == var_other;
9383 var12 = var14;
9384 goto RET_LABEL13;
9385 RET_LABEL13:(void)0;
9386 }
9387 }
9388 var10 = var12;
9389 goto RET_LABEL11;
9390 RET_LABEL11:(void)0;
9391 }
9392 var9 = var10;
9393 }
9394 if (var9){
9395 /* <var_new_child:nullable ANode> isa nullable TKwredef */
9396 cltype16 = type_nullable_parser_nodes__TKwredef.color;
9397 idtype17 = type_nullable_parser_nodes__TKwredef.id;
9398 if(var_new_child == NULL) {
9399 var15 = 1;
9400 } else {
9401 if(cltype16 >= var_new_child->type->table_size) {
9402 var15 = 0;
9403 } else {
9404 var15 = var_new_child->type->type_table[cltype16] == idtype17;
9405 }
9406 }
9407 if (unlikely(!var15)) {
9408 var_class_name18 = var_new_child == NULL ? "null" : var_new_child->type->name;
9409 PRINT_ERROR("Runtime error: Cast failed. Expected `%s`, got `%s`", "nullable TKwredef", var_class_name18);
9410 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 1308);
9411 show_backtrace(1);
9412 }
9413 {
9414 parser_prod__AInternNewPropdef__n_kwredef_61d(self, var_new_child); /* Direct call parser_prod#AInternNewPropdef#n_kwredef= on <self:AInternNewPropdef>*/
9415 }
9416 goto RET_LABEL;
9417 } else {
9418 }
9419 var19 = self->attrs[COLOR_parser_nodes__APropdef___n_visibility].val; /* _n_visibility on <self:AInternNewPropdef> */
9420 if (var19 == NULL) {
9421 var20 = 0; /* <var_old_child:ANode> cannot be null */
9422 } else {
9423 { /* Inline kernel#Object#== (var19,var_old_child) on <var19:nullable AVisibility> */
9424 var_other = var_old_child;
9425 {
9426 { /* Inline kernel#Object#is_same_instance (var19,var_other) on <var19:nullable AVisibility(AVisibility)> */
9427 var25 = var19 == var_other;
9428 var23 = var25;
9429 goto RET_LABEL24;
9430 RET_LABEL24:(void)0;
9431 }
9432 }
9433 var21 = var23;
9434 goto RET_LABEL22;
9435 RET_LABEL22:(void)0;
9436 }
9437 var20 = var21;
9438 }
9439 if (var20){
9440 /* <var_new_child:nullable ANode> isa AVisibility */
9441 cltype27 = type_parser_nodes__AVisibility.color;
9442 idtype28 = type_parser_nodes__AVisibility.id;
9443 if(var_new_child == NULL) {
9444 var26 = 0;
9445 } else {
9446 if(cltype27 >= var_new_child->type->table_size) {
9447 var26 = 0;
9448 } else {
9449 var26 = var_new_child->type->type_table[cltype27] == idtype28;
9450 }
9451 }
9452 if (unlikely(!var26)) {
9453 var_class_name29 = var_new_child == NULL ? "null" : var_new_child->type->name;
9454 PRINT_ERROR("Runtime error: Cast failed. Expected `%s`, got `%s`", "AVisibility", var_class_name29);
9455 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 1312);
9456 show_backtrace(1);
9457 }
9458 {
9459 parser_prod__AInternNewPropdef__n_visibility_61d(self, var_new_child); /* Direct call parser_prod#AInternNewPropdef#n_visibility= on <self:AInternNewPropdef>*/
9460 }
9461 goto RET_LABEL;
9462 } else {
9463 }
9464 var30 = self->attrs[COLOR_parser_nodes__AMethPropdef___n_kwnew].val; /* _n_kwnew on <self:AInternNewPropdef> */
9465 if (var30 == NULL) {
9466 var31 = 0; /* <var_old_child:ANode> cannot be null */
9467 } else {
9468 { /* Inline kernel#Object#== (var30,var_old_child) on <var30:nullable TKwnew> */
9469 var_other = var_old_child;
9470 {
9471 { /* Inline kernel#Object#is_same_instance (var30,var_other) on <var30:nullable TKwnew(TKwnew)> */
9472 var36 = var30 == var_other;
9473 var34 = var36;
9474 goto RET_LABEL35;
9475 RET_LABEL35:(void)0;
9476 }
9477 }
9478 var32 = var34;
9479 goto RET_LABEL33;
9480 RET_LABEL33:(void)0;
9481 }
9482 var31 = var32;
9483 }
9484 if (var31){
9485 /* <var_new_child:nullable ANode> isa TKwnew */
9486 cltype38 = type_parser_nodes__TKwnew.color;
9487 idtype39 = type_parser_nodes__TKwnew.id;
9488 if(var_new_child == NULL) {
9489 var37 = 0;
9490 } else {
9491 if(cltype38 >= var_new_child->type->table_size) {
9492 var37 = 0;
9493 } else {
9494 var37 = var_new_child->type->type_table[cltype38] == idtype39;
9495 }
9496 }
9497 if (unlikely(!var37)) {
9498 var_class_name40 = var_new_child == NULL ? "null" : var_new_child->type->name;
9499 PRINT_ERROR("Runtime error: Cast failed. Expected `%s`, got `%s`", "TKwnew", var_class_name40);
9500 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 1316);
9501 show_backtrace(1);
9502 }
9503 {
9504 parser_prod__AInternNewPropdef__n_kwnew_61d(self, var_new_child); /* Direct call parser_prod#AInternNewPropdef#n_kwnew= on <self:AInternNewPropdef>*/
9505 }
9506 goto RET_LABEL;
9507 } else {
9508 }
9509 var41 = self->attrs[COLOR_parser_nodes__AMethPropdef___n_methid].val; /* _n_methid on <self:AInternNewPropdef> */
9510 if (var41 == NULL) {
9511 var42 = 0; /* <var_old_child:ANode> cannot be null */
9512 } else {
9513 { /* Inline kernel#Object#== (var41,var_old_child) on <var41:nullable AMethid> */
9514 var_other = var_old_child;
9515 {
9516 { /* Inline kernel#Object#is_same_instance (var41,var_other) on <var41:nullable AMethid(AMethid)> */
9517 var47 = var41 == var_other;
9518 var45 = var47;
9519 goto RET_LABEL46;
9520 RET_LABEL46:(void)0;
9521 }
9522 }
9523 var43 = var45;
9524 goto RET_LABEL44;
9525 RET_LABEL44:(void)0;
9526 }
9527 var42 = var43;
9528 }
9529 if (var42){
9530 /* <var_new_child:nullable ANode> isa nullable AMethid */
9531 cltype49 = type_nullable_parser_nodes__AMethid.color;
9532 idtype50 = type_nullable_parser_nodes__AMethid.id;
9533 if(var_new_child == NULL) {
9534 var48 = 1;
9535 } else {
9536 if(cltype49 >= var_new_child->type->table_size) {
9537 var48 = 0;
9538 } else {
9539 var48 = var_new_child->type->type_table[cltype49] == idtype50;
9540 }
9541 }
9542 if (unlikely(!var48)) {
9543 var_class_name51 = var_new_child == NULL ? "null" : var_new_child->type->name;
9544 PRINT_ERROR("Runtime error: Cast failed. Expected `%s`, got `%s`", "nullable AMethid", var_class_name51);
9545 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 1320);
9546 show_backtrace(1);
9547 }
9548 {
9549 parser_prod__AInternNewPropdef__n_methid_61d(self, var_new_child); /* Direct call parser_prod#AInternNewPropdef#n_methid= on <self:AInternNewPropdef>*/
9550 }
9551 goto RET_LABEL;
9552 } else {
9553 }
9554 var52 = self->attrs[COLOR_parser_nodes__AMethPropdef___n_signature].val; /* _n_signature on <self:AInternNewPropdef> */
9555 if (var52 == NULL) {
9556 var53 = 0; /* <var_old_child:ANode> cannot be null */
9557 } else {
9558 { /* Inline kernel#Object#== (var52,var_old_child) on <var52:nullable ASignature> */
9559 var_other = var_old_child;
9560 {
9561 { /* Inline kernel#Object#is_same_instance (var52,var_other) on <var52:nullable ASignature(ASignature)> */
9562 var58 = var52 == var_other;
9563 var56 = var58;
9564 goto RET_LABEL57;
9565 RET_LABEL57:(void)0;
9566 }
9567 }
9568 var54 = var56;
9569 goto RET_LABEL55;
9570 RET_LABEL55:(void)0;
9571 }
9572 var53 = var54;
9573 }
9574 if (var53){
9575 /* <var_new_child:nullable ANode> isa ASignature */
9576 cltype60 = type_parser_nodes__ASignature.color;
9577 idtype61 = type_parser_nodes__ASignature.id;
9578 if(var_new_child == NULL) {
9579 var59 = 0;
9580 } else {
9581 if(cltype60 >= var_new_child->type->table_size) {
9582 var59 = 0;
9583 } else {
9584 var59 = var_new_child->type->type_table[cltype60] == idtype61;
9585 }
9586 }
9587 if (unlikely(!var59)) {
9588 var_class_name62 = var_new_child == NULL ? "null" : var_new_child->type->name;
9589 PRINT_ERROR("Runtime error: Cast failed. Expected `%s`, got `%s`", "ASignature", var_class_name62);
9590 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 1324);
9591 show_backtrace(1);
9592 }
9593 {
9594 parser_prod__AInternNewPropdef__n_signature_61d(self, var_new_child); /* Direct call parser_prod#AInternNewPropdef#n_signature= on <self:AInternNewPropdef>*/
9595 }
9596 goto RET_LABEL;
9597 } else {
9598 }
9599 RET_LABEL:;
9600 }
9601 /* method parser_prod#AInternNewPropdef#replace_child for (self: Object, ANode, nullable ANode) */
9602 void VIRTUAL_parser_prod__AInternNewPropdef__replace_child(val* self, val* p0, val* p1) {
9603 parser_prod__AInternNewPropdef__replace_child(self, p0, p1); /* Direct call parser_prod#AInternNewPropdef#replace_child on <self:Object(AInternNewPropdef)>*/
9604 RET_LABEL:;
9605 }
9606 /* method parser_prod#AInternNewPropdef#n_doc= for (self: AInternNewPropdef, nullable ADoc) */
9607 void parser_prod__AInternNewPropdef__n_doc_61d(val* self, val* p0) {
9608 val* var_node /* var node: nullable ADoc */;
9609 val* var /* : null */;
9610 short int var1 /* : Bool */;
9611 short int var2 /* : Bool */;
9612 val* var_other /* var other: nullable Object */;
9613 short int var4 /* : Bool */;
9614 short int var5 /* : Bool */;
9615 short int var6 /* : Bool */;
9616 var_node = p0;
9617 self->attrs[COLOR_parser_nodes__APropdef___n_doc].val = var_node; /* _n_doc on <self:AInternNewPropdef> */
9618 var = NULL;
9619 if (var_node == NULL) {
9620 var1 = 0; /* is null */
9621 } else {
9622 var1 = 1; /* arg is null and recv is not */
9623 }
9624 if (0) {
9625 { /* Inline kernel#Object#!= (var_node,var) on <var_node:nullable ADoc> */
9626 var_other = var;
9627 {
9628 var5 = ((short int (*)(val*, val*))(var_node->class->vft[COLOR_kernel__Object___61d_61d]))(var_node, var_other) /* == on <var_node:nullable ADoc(ADoc)>*/;
9629 var4 = var5;
9630 }
9631 var6 = !var4;
9632 var2 = var6;
9633 goto RET_LABEL3;
9634 RET_LABEL3:(void)0;
9635 }
9636 var1 = var2;
9637 }
9638 if (var1){
9639 {
9640 { /* Inline parser_nodes#ANode#parent= (var_node,self) on <var_node:nullable ADoc(ADoc)> */
9641 var_node->attrs[COLOR_parser_nodes__ANode___parent].val = self; /* _parent on <var_node:nullable ADoc(ADoc)> */
9642 RET_LABEL7:(void)0;
9643 }
9644 }
9645 } else {
9646 }
9647 RET_LABEL:;
9648 }
9649 /* method parser_prod#AInternNewPropdef#n_doc= for (self: Object, nullable ADoc) */
9650 void VIRTUAL_parser_prod__AInternNewPropdef__n_doc_61d(val* self, val* p0) {
9651 parser_prod__AInternNewPropdef__n_doc_61d(self, p0); /* Direct call parser_prod#AInternNewPropdef#n_doc= on <self:Object(AInternNewPropdef)>*/
9652 RET_LABEL:;
9653 }
9654 /* method parser_prod#AInternNewPropdef#n_kwredef= for (self: AInternNewPropdef, nullable TKwredef) */
9655 void parser_prod__AInternNewPropdef__n_kwredef_61d(val* self, val* p0) {
9656 val* var_node /* var node: nullable TKwredef */;
9657 val* var /* : null */;
9658 short int var1 /* : Bool */;
9659 short int var2 /* : Bool */;
9660 val* var_other /* var other: nullable Object */;
9661 short int var4 /* : Bool */;
9662 short int var5 /* : Bool */;
9663 short int var6 /* : Bool */;
9664 var_node = p0;
9665 self->attrs[COLOR_parser_nodes__APropdef___n_kwredef].val = var_node; /* _n_kwredef on <self:AInternNewPropdef> */
9666 var = NULL;
9667 if (var_node == NULL) {
9668 var1 = 0; /* is null */
9669 } else {
9670 var1 = 1; /* arg is null and recv is not */
9671 }
9672 if (0) {
9673 { /* Inline kernel#Object#!= (var_node,var) on <var_node:nullable TKwredef> */
9674 var_other = var;
9675 {
9676 var5 = ((short int (*)(val*, val*))(var_node->class->vft[COLOR_kernel__Object___61d_61d]))(var_node, var_other) /* == on <var_node:nullable TKwredef(TKwredef)>*/;
9677 var4 = var5;
9678 }
9679 var6 = !var4;
9680 var2 = var6;
9681 goto RET_LABEL3;
9682 RET_LABEL3:(void)0;
9683 }
9684 var1 = var2;
9685 }
9686 if (var1){
9687 {
9688 { /* Inline parser_nodes#ANode#parent= (var_node,self) on <var_node:nullable TKwredef(TKwredef)> */
9689 var_node->attrs[COLOR_parser_nodes__ANode___parent].val = self; /* _parent on <var_node:nullable TKwredef(TKwredef)> */
9690 RET_LABEL7:(void)0;
9691 }
9692 }
9693 } else {
9694 }
9695 RET_LABEL:;
9696 }
9697 /* method parser_prod#AInternNewPropdef#n_kwredef= for (self: Object, nullable TKwredef) */
9698 void VIRTUAL_parser_prod__AInternNewPropdef__n_kwredef_61d(val* self, val* p0) {
9699 parser_prod__AInternNewPropdef__n_kwredef_61d(self, p0); /* Direct call parser_prod#AInternNewPropdef#n_kwredef= on <self:Object(AInternNewPropdef)>*/
9700 RET_LABEL:;
9701 }
9702 /* method parser_prod#AInternNewPropdef#n_visibility= for (self: AInternNewPropdef, nullable AVisibility) */
9703 void parser_prod__AInternNewPropdef__n_visibility_61d(val* self, val* p0) {
9704 val* var_node /* var node: nullable AVisibility */;
9705 var_node = p0;
9706 self->attrs[COLOR_parser_nodes__APropdef___n_visibility].val = var_node; /* _n_visibility on <self:AInternNewPropdef> */
9707 if (var_node == NULL) {
9708 PRINT_ERROR("Runtime error: %s", "Receiver is null");
9709 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 1342);
9710 show_backtrace(1);
9711 } else {
9712 { /* Inline parser_nodes#ANode#parent= (var_node,self) on <var_node:nullable AVisibility> */
9713 if (unlikely(var_node == NULL)) {
9714 PRINT_ERROR("Runtime error: %s", "Receiver is null");
9715 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_nodes.nit", 38);
9716 show_backtrace(1);
9717 }
9718 var_node->attrs[COLOR_parser_nodes__ANode___parent].val = self; /* _parent on <var_node:nullable AVisibility> */
9719 RET_LABEL1:(void)0;
9720 }
9721 }
9722 RET_LABEL:;
9723 }
9724 /* method parser_prod#AInternNewPropdef#n_visibility= for (self: Object, nullable AVisibility) */
9725 void VIRTUAL_parser_prod__AInternNewPropdef__n_visibility_61d(val* self, val* p0) {
9726 parser_prod__AInternNewPropdef__n_visibility_61d(self, p0); /* Direct call parser_prod#AInternNewPropdef#n_visibility= on <self:Object(AInternNewPropdef)>*/
9727 RET_LABEL:;
9728 }
9729 /* method parser_prod#AInternNewPropdef#n_kwnew= for (self: AInternNewPropdef, nullable TKwnew) */
9730 void parser_prod__AInternNewPropdef__n_kwnew_61d(val* self, val* p0) {
9731 val* var_node /* var node: nullable TKwnew */;
9732 var_node = p0;
9733 self->attrs[COLOR_parser_nodes__AMethPropdef___n_kwnew].val = var_node; /* _n_kwnew on <self:AInternNewPropdef> */
9734 if (var_node == NULL) {
9735 PRINT_ERROR("Runtime error: %s", "Receiver is null");
9736 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 1347);
9737 show_backtrace(1);
9738 } else {
9739 { /* Inline parser_nodes#ANode#parent= (var_node,self) on <var_node:nullable TKwnew> */
9740 if (unlikely(var_node == NULL)) {
9741 PRINT_ERROR("Runtime error: %s", "Receiver is null");
9742 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_nodes.nit", 38);
9743 show_backtrace(1);
9744 }
9745 var_node->attrs[COLOR_parser_nodes__ANode___parent].val = self; /* _parent on <var_node:nullable TKwnew> */
9746 RET_LABEL1:(void)0;
9747 }
9748 }
9749 RET_LABEL:;
9750 }
9751 /* method parser_prod#AInternNewPropdef#n_kwnew= for (self: Object, nullable TKwnew) */
9752 void VIRTUAL_parser_prod__AInternNewPropdef__n_kwnew_61d(val* self, val* p0) {
9753 parser_prod__AInternNewPropdef__n_kwnew_61d(self, p0); /* Direct call parser_prod#AInternNewPropdef#n_kwnew= on <self:Object(AInternNewPropdef)>*/
9754 RET_LABEL:;
9755 }
9756 /* method parser_prod#AInternNewPropdef#n_methid= for (self: AInternNewPropdef, nullable AMethid) */
9757 void parser_prod__AInternNewPropdef__n_methid_61d(val* self, val* p0) {
9758 val* var_node /* var node: nullable AMethid */;
9759 val* var /* : null */;
9760 short int var1 /* : Bool */;
9761 short int var2 /* : Bool */;
9762 val* var_other /* var other: nullable Object */;
9763 short int var4 /* : Bool */;
9764 short int var5 /* : Bool */;
9765 short int var6 /* : Bool */;
9766 var_node = p0;
9767 self->attrs[COLOR_parser_nodes__AMethPropdef___n_methid].val = var_node; /* _n_methid on <self:AInternNewPropdef> */
9768 var = NULL;
9769 if (var_node == NULL) {
9770 var1 = 0; /* is null */
9771 } else {
9772 var1 = 1; /* arg is null and recv is not */
9773 }
9774 if (0) {
9775 { /* Inline kernel#Object#!= (var_node,var) on <var_node:nullable AMethid> */
9776 var_other = var;
9777 {
9778 var5 = ((short int (*)(val*, val*))(var_node->class->vft[COLOR_kernel__Object___61d_61d]))(var_node, var_other) /* == on <var_node:nullable AMethid(AMethid)>*/;
9779 var4 = var5;
9780 }
9781 var6 = !var4;
9782 var2 = var6;
9783 goto RET_LABEL3;
9784 RET_LABEL3:(void)0;
9785 }
9786 var1 = var2;
9787 }
9788 if (var1){
9789 {
9790 { /* Inline parser_nodes#ANode#parent= (var_node,self) on <var_node:nullable AMethid(AMethid)> */
9791 var_node->attrs[COLOR_parser_nodes__ANode___parent].val = self; /* _parent on <var_node:nullable AMethid(AMethid)> */
9792 RET_LABEL7:(void)0;
9793 }
9794 }
9795 } else {
9796 }
9797 RET_LABEL:;
9798 }
9799 /* method parser_prod#AInternNewPropdef#n_methid= for (self: Object, nullable AMethid) */
9800 void VIRTUAL_parser_prod__AInternNewPropdef__n_methid_61d(val* self, val* p0) {
9801 parser_prod__AInternNewPropdef__n_methid_61d(self, p0); /* Direct call parser_prod#AInternNewPropdef#n_methid= on <self:Object(AInternNewPropdef)>*/
9802 RET_LABEL:;
9803 }
9804 /* method parser_prod#AInternNewPropdef#n_signature= for (self: AInternNewPropdef, nullable ASignature) */
9805 void parser_prod__AInternNewPropdef__n_signature_61d(val* self, val* p0) {
9806 val* var_node /* var node: nullable ASignature */;
9807 var_node = p0;
9808 self->attrs[COLOR_parser_nodes__AMethPropdef___n_signature].val = var_node; /* _n_signature on <self:AInternNewPropdef> */
9809 if (var_node == NULL) {
9810 PRINT_ERROR("Runtime error: %s", "Receiver is null");
9811 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_prod.nit", 1357);
9812 show_backtrace(1);
9813 } else {
9814 { /* Inline parser_nodes#ANode#parent= (var_node,self) on <var_node:nullable ASignature> */
9815 if (unlikely(var_node == NULL)) {
9816 PRINT_ERROR("Runtime error: %s", "Receiver is null");
9817 PRINT_ERROR(" (%s:%d)\n", "src/parser/parser_nodes.nit", 38);
9818 show_backtrace(1);
9819 }
9820 var_node->attrs[COLOR_parser_nodes__ANode___parent].val = self; /* _parent on <var_node:nullable ASignature> */
9821 RET_LABEL1:(void)0;
9822 }
9823 }
9824 RET_LABEL:;
9825 }
9826 /* method parser_prod#AInternNewPropdef#n_signature= for (self: Object, nullable ASignature) */
9827 void VIRTUAL_parser_prod__AInternNewPropdef__n_signature_61d(val* self, val* p0) {
9828 parser_prod__AInternNewPropdef__n_signature_61d(self, p0); /* Direct call parser_prod#AInternNewPropdef#n_signature= on <self:Object(AInternNewPropdef)>*/
9829 RET_LABEL:;
9830 }
9831 /* method parser_prod#AInternNewPropdef#visit_all for (self: AInternNewPropdef, Visitor) */
9832 void parser_prod__AInternNewPropdef__visit_all(val* self, val* p0) {
9833 val* var_v /* var v: Visitor */;
9834 val* var /* : nullable ADoc */;
9835 val* var1 /* : nullable TKwredef */;
9836 val* var2 /* : nullable AVisibility */;
9837 val* var3 /* : nullable TKwnew */;
9838 val* var4 /* : nullable AMethid */;
9839 val* var5 /* : nullable ASignature */;
9840 var_v = p0;
9841 var = self->attrs[COLOR_parser_nodes__APropdef___n_doc].val; /* _n_doc on <self:AInternNewPropdef> */
9842 {
9843 parser_nodes__Visitor__enter_visit(var_v, var); /* Direct call parser_nodes#Visitor#enter_visit on <var_v:Visitor>*/
9844 }
9845 var1 = self->attrs[COLOR_parser_nodes__APropdef___n_kwredef].val; /* _n_kwredef on <self:AInternNewPropdef> */
9846 {
9847 parser_nodes__Visitor__enter_visit(var_v, var1); /* Direct call parser_nodes#Visitor#enter_visit on <var_v:Visitor>*/
9848 }
9849 var2 = self->attrs[COLOR_parser_nodes__APropdef___n_visibility].val; /* _n_visibility on <self:AInternNewPropdef> */
9850 {
9851 parser_nodes__Visitor__enter_visit(var_v, var2); /* Direct call parser_nodes#Visitor#enter_visit on <var_v:Visitor>*/
9852 }
9853 var3 = self->attrs[COLOR_parser_nodes__AMethPropdef___n_kwnew].val; /* _n_kwnew on <self:AInternNewPropdef> */
9854 {
9855 parser_nodes__Visitor__enter_visit(var_v, var3); /* Direct call parser_nodes#Visitor#enter_visit on <var_v:Visitor>*/
9856 }
9857 var4 = self->attrs[COLOR_parser_nodes__AMethPropdef___n_methid].val; /* _n_methid on <self:AInternNewPropdef> */
9858 {
9859 parser_nodes__Visitor__enter_visit(var_v, var4); /* Direct call parser_nodes#Visitor#enter_visit on <var_v:Visitor>*/
9860 }
9861 var5 = self->attrs[COLOR_parser_nodes__AMethPropdef___n_signature].val; /* _n_signature on <self:AInternNewPropdef> */
9862 {
9863 parser_nodes__Visitor__enter_visit(var_v, var5); /* Direct call parser_nodes#Visitor#enter_visit on <var_v:Visitor>*/
9864 }
9865 RET_LABEL:;
9866 }
9867 /* method parser_prod#AInternNewPropdef#visit_all for (self: Object, Visitor) */
9868 void VIRTUAL_parser_prod__AInternNewPropdef__visit_all(val* self, val* p0) {
9869 parser_prod__AInternNewPropdef__visit_all(self, p0); /* Direct call parser_prod#AInternNewPropdef#visit_all on <self:Object(AInternNewPropdef)>*/
9870 RET_LABEL:;
9871 }