1 #include "abstract_collection.sep.0.h"
2 /* method abstract_collection#Collection#iterator for (self: Collection[nullable Object]): Iterator[nullable Object] */
3 val
* abstract_collection__Collection__iterator(val
* self
) {
4 val
* var
/* : Iterator[nullable Object] */;
5 const char* var_class_name
;
6 var_class_name
= self
== NULL ?
"null" : self
->type
->name
;
7 fprintf(stderr
, "Runtime error: Abstract method `%s` called on `%s`", "iterator", var_class_name
);
8 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 54);
13 /* method abstract_collection#Collection#iterator for (self: Object): Iterator[nullable Object] */
14 val
* VIRTUAL_abstract_collection__Collection__iterator(val
* self
) {
15 val
* var
/* : Iterator[nullable Object] */;
16 val
* var1
/* : Iterator[nullable Object] */;
17 var1
= abstract_collection__Collection__iterator(self
);
22 /* method abstract_collection#Collection#is_empty for (self: Collection[nullable Object]): Bool */
23 short int abstract_collection__Collection__is_empty(val
* self
) {
24 short int var
/* : Bool */;
25 long var1
/* : Int */;
26 long var2
/* : Int */;
27 short int var3
/* : Bool */;
28 short int var5
/* : Bool */;
29 var1
= ((long (*)(val
*))(self
->class->vft
[COLOR_abstract_collection__Collection__length
]))(self
) /* length on <self:Collection[nullable Object]>*/;
31 { /* Inline kernel#Int#== (var1,var2) */
42 /* method abstract_collection#Collection#is_empty for (self: Object): Bool */
43 short int VIRTUAL_abstract_collection__Collection__is_empty(val
* self
) {
44 short int var
/* : Bool */;
45 short int var1
/* : Bool */;
46 var1
= abstract_collection__Collection__is_empty(self
);
51 /* method abstract_collection#Collection#length for (self: Collection[nullable Object]): Int */
52 long abstract_collection__Collection__length(val
* self
) {
54 long var1
/* : Int */;
55 long var_nb
/* var nb: Int */;
56 val
* var2
/* : Iterator[nullable Object] */;
57 short int var3
/* : Bool */;
58 val
* var4
/* : nullable Object */;
59 val
* var_i
/* var i: nullable Object */;
60 long var5
/* : Int */;
61 long var6
/* : Int */;
62 long var8
/* : Int */;
65 var2
= ((val
* (*)(val
*))(self
->class->vft
[COLOR_abstract_collection__Collection__iterator
]))(self
) /* iterator on <self:Collection[nullable Object]>*/;
67 var3
= ((short int (*)(val
*))(var2
->class->vft
[COLOR_abstract_collection__Iterator__is_ok
]))(var2
) /* is_ok on <var2:Iterator[nullable Object]>*/;
69 var4
= ((val
* (*)(val
*))(var2
->class->vft
[COLOR_abstract_collection__Iterator__item
]))(var2
) /* item on <var2:Iterator[nullable Object]>*/;
72 { /* Inline kernel#Int#+ (var_nb,var5) */
79 CONTINUE_label
: (void)0;
80 ((void (*)(val
*))(var2
->class->vft
[COLOR_abstract_collection__Iterator__next
]))(var2
) /* next on <var2:Iterator[nullable Object]>*/;
88 /* method abstract_collection#Collection#length for (self: Object): Int */
89 long VIRTUAL_abstract_collection__Collection__length(val
* self
) {
91 long var1
/* : Int */;
92 var1
= abstract_collection__Collection__length(self
);
97 /* method abstract_collection#Collection#has for (self: Collection[nullable Object], nullable Object): Bool */
98 short int abstract_collection__Collection__has(val
* self
, val
* p0
) {
99 short int var
/* : Bool */;
100 short int var1
/* : Bool */;
103 const struct type
* type_struct
;
104 short int is_nullable
;
105 const char* var_class_name
;
106 val
* var_item
/* var item: nullable Object */;
107 val
* var2
/* : Iterator[nullable Object] */;
108 short int var3
/* : Bool */;
109 val
* var4
/* : nullable Object */;
110 val
* var_i
/* var i: nullable Object */;
111 short int var5
/* : Bool */;
112 short int var6
/* : Bool */;
113 short int var7
/* : Bool */;
114 /* Covariant cast for argument 0 (item) <p0:nullable Object> isa Collection#0 */
115 /* <p0:nullable Object> isa Collection#0 */
116 type_struct
= self
->type
->resolution_table
->types
[COLOR_abstract_collection__Collection_FT0
];
117 cltype
= type_struct
->color
;
118 idtype
= type_struct
->id
;
119 is_nullable
= type_struct
->is_nullable
;
123 if(cltype
>= p0
->type
->table_size
) {
126 var1
= p0
->type
->type_table
[cltype
] == idtype
;
130 var_class_name
= p0
== NULL ?
"null" : p0
->type
->name
;
131 fprintf(stderr
, "Runtime error: Cast failed. Expected `%s`, got `%s`", "Collection#0", var_class_name
);
132 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 75);
136 var2
= ((val
* (*)(val
*))(self
->class->vft
[COLOR_abstract_collection__Collection__iterator
]))(self
) /* iterator on <self:Collection[nullable Object]>*/;
138 var3
= ((short int (*)(val
*))(var2
->class->vft
[COLOR_abstract_collection__Iterator__is_ok
]))(var2
) /* is_ok on <var2:Iterator[nullable Object]>*/;
140 var4
= ((val
* (*)(val
*))(var2
->class->vft
[COLOR_abstract_collection__Iterator__item
]))(var2
) /* item on <var2:Iterator[nullable Object]>*/;
143 var5
= (var_item
== NULL
);
145 var5
= ((short int (*)(val
*, val
*))(var_i
->class->vft
[COLOR_kernel__Object___61d_61d
]))(var_i
, var_item
) /* == on <var_i:nullable Object>*/;
153 CONTINUE_label
: (void)0;
154 ((void (*)(val
*))(var2
->class->vft
[COLOR_abstract_collection__Iterator__next
]))(var2
) /* next on <var2:Iterator[nullable Object]>*/;
156 BREAK_label
: (void)0;
163 /* method abstract_collection#Collection#has for (self: Object, nullable Object): Bool */
164 short int VIRTUAL_abstract_collection__Collection__has(val
* self
, val
* p0
) {
165 short int var
/* : Bool */;
166 short int var1
/* : Bool */;
167 var1
= abstract_collection__Collection__has(self
, p0
);
172 /* method abstract_collection#Collection#has_only for (self: Collection[nullable Object], nullable Object): Bool */
173 short int abstract_collection__Collection__has_only(val
* self
, val
* p0
) {
174 short int var
/* : Bool */;
175 short int var1
/* : Bool */;
178 const struct type
* type_struct
;
179 short int is_nullable
;
180 const char* var_class_name
;
181 val
* var_item
/* var item: nullable Object */;
182 val
* var2
/* : Iterator[nullable Object] */;
183 short int var3
/* : Bool */;
184 val
* var4
/* : nullable Object */;
185 val
* var_i
/* var i: nullable Object */;
186 short int var5
/* : Bool */;
187 short int var6
/* : Bool */;
188 short int var7
/* : Bool */;
189 /* Covariant cast for argument 0 (item) <p0:nullable Object> isa Collection#0 */
190 /* <p0:nullable Object> isa Collection#0 */
191 type_struct
= self
->type
->resolution_table
->types
[COLOR_abstract_collection__Collection_FT0
];
192 cltype
= type_struct
->color
;
193 idtype
= type_struct
->id
;
194 is_nullable
= type_struct
->is_nullable
;
198 if(cltype
>= p0
->type
->table_size
) {
201 var1
= p0
->type
->type_table
[cltype
] == idtype
;
205 var_class_name
= p0
== NULL ?
"null" : p0
->type
->name
;
206 fprintf(stderr
, "Runtime error: Cast failed. Expected `%s`, got `%s`", "Collection#0", var_class_name
);
207 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 88);
211 var2
= ((val
* (*)(val
*))(self
->class->vft
[COLOR_abstract_collection__Collection__iterator
]))(self
) /* iterator on <self:Collection[nullable Object]>*/;
213 var3
= ((short int (*)(val
*))(var2
->class->vft
[COLOR_abstract_collection__Iterator__is_ok
]))(var2
) /* is_ok on <var2:Iterator[nullable Object]>*/;
215 var4
= ((val
* (*)(val
*))(var2
->class->vft
[COLOR_abstract_collection__Iterator__item
]))(var2
) /* item on <var2:Iterator[nullable Object]>*/;
218 var5
= (var_item
!= NULL
);
220 var5
= ((short int (*)(val
*, val
*))(var_i
->class->vft
[COLOR_kernel__Object___33d_61d
]))(var_i
, var_item
) /* != on <var_i:nullable Object>*/;
228 CONTINUE_label
: (void)0;
229 ((void (*)(val
*))(var2
->class->vft
[COLOR_abstract_collection__Iterator__next
]))(var2
) /* next on <var2:Iterator[nullable Object]>*/;
231 BREAK_label
: (void)0;
238 /* method abstract_collection#Collection#has_only for (self: Object, nullable Object): Bool */
239 short int VIRTUAL_abstract_collection__Collection__has_only(val
* self
, val
* p0
) {
240 short int var
/* : Bool */;
241 short int var1
/* : Bool */;
242 var1
= abstract_collection__Collection__has_only(self
, p0
);
247 /* method abstract_collection#Collection#count for (self: Collection[nullable Object], nullable Object): Int */
248 long abstract_collection__Collection__count(val
* self
, val
* p0
) {
249 long var
/* : Int */;
250 short int var1
/* : Bool */;
253 const struct type
* type_struct
;
254 short int is_nullable
;
255 const char* var_class_name
;
256 val
* var_item
/* var item: nullable Object */;
257 long var2
/* : Int */;
258 long var_nb
/* var nb: Int */;
259 val
* var3
/* : Iterator[nullable Object] */;
260 short int var4
/* : Bool */;
261 val
* var5
/* : nullable Object */;
262 val
* var_i
/* var i: nullable Object */;
263 short int var6
/* : Bool */;
264 long var7
/* : Int */;
265 long var8
/* : Int */;
266 long var10
/* : Int */;
267 /* Covariant cast for argument 0 (item) <p0:nullable Object> isa Collection#0 */
268 /* <p0:nullable Object> isa Collection#0 */
269 type_struct
= self
->type
->resolution_table
->types
[COLOR_abstract_collection__Collection_FT0
];
270 cltype
= type_struct
->color
;
271 idtype
= type_struct
->id
;
272 is_nullable
= type_struct
->is_nullable
;
276 if(cltype
>= p0
->type
->table_size
) {
279 var1
= p0
->type
->type_table
[cltype
] == idtype
;
283 var_class_name
= p0
== NULL ?
"null" : p0
->type
->name
;
284 fprintf(stderr
, "Runtime error: Cast failed. Expected `%s`, got `%s`", "Collection#0", var_class_name
);
285 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 105);
291 var3
= ((val
* (*)(val
*))(self
->class->vft
[COLOR_abstract_collection__Collection__iterator
]))(self
) /* iterator on <self:Collection[nullable Object]>*/;
293 var4
= ((short int (*)(val
*))(var3
->class->vft
[COLOR_abstract_collection__Iterator__is_ok
]))(var3
) /* is_ok on <var3:Iterator[nullable Object]>*/;
295 var5
= ((val
* (*)(val
*))(var3
->class->vft
[COLOR_abstract_collection__Iterator__item
]))(var3
) /* item on <var3:Iterator[nullable Object]>*/;
298 var6
= (var_item
== NULL
);
300 var6
= ((short int (*)(val
*, val
*))(var_i
->class->vft
[COLOR_kernel__Object___61d_61d
]))(var_i
, var_item
) /* == on <var_i:nullable Object>*/;
304 { /* Inline kernel#Int#+ (var_nb,var7) */
305 var10
= var_nb
+ var7
;
313 CONTINUE_label
: (void)0;
314 ((void (*)(val
*))(var3
->class->vft
[COLOR_abstract_collection__Iterator__next
]))(var3
) /* next on <var3:Iterator[nullable Object]>*/;
316 BREAK_label
: (void)0;
322 /* method abstract_collection#Collection#count for (self: Object, nullable Object): Int */
323 long VIRTUAL_abstract_collection__Collection__count(val
* self
, val
* p0
) {
324 long var
/* : Int */;
325 long var1
/* : Int */;
326 var1
= abstract_collection__Collection__count(self
, p0
);
331 /* method abstract_collection#Collection#first for (self: Collection[nullable Object]): nullable Object */
332 val
* abstract_collection__Collection__first(val
* self
) {
333 val
* var
/* : nullable Object */;
334 long var1
/* : Int */;
335 long var2
/* : Int */;
336 short int var3
/* : Bool */;
337 short int var5
/* : Bool */;
340 const char* var_class_name
;
341 short int var6
/* : Bool */;
342 val
* var7
/* : Iterator[nullable Object] */;
343 val
* var8
/* : nullable Object */;
344 var1
= ((long (*)(val
*))(self
->class->vft
[COLOR_abstract_collection__Collection__length
]))(self
) /* length on <self:Collection[nullable Object]>*/;
346 { /* Inline kernel#Int#> (var1,var2) */
347 /* Covariant cast for argument 0 (i) <var2:Int> isa OTHER */
348 /* <var2:Int> isa OTHER */
349 var5
= 1; /* easy <var2:Int> isa OTHER*/
351 var_class_name
= type_kernel__Int
.name
;
352 fprintf(stderr
, "Runtime error: Cast failed. Expected `%s`, got `%s`", "OTHER", var_class_name
);
353 fprintf(stderr
, " (%s:%d)\n", "lib/standard/kernel.nit", 263);
362 fprintf(stderr
, "Runtime error: %s", "Assert failed");
363 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 121);
366 var7
= ((val
* (*)(val
*))(self
->class->vft
[COLOR_abstract_collection__Collection__iterator
]))(self
) /* iterator on <self:Collection[nullable Object]>*/;
367 var8
= ((val
* (*)(val
*))(var7
->class->vft
[COLOR_abstract_collection__Iterator__item
]))(var7
) /* item on <var7:Iterator[nullable Object]>*/;
373 /* method abstract_collection#Collection#first for (self: Object): nullable Object */
374 val
* VIRTUAL_abstract_collection__Collection__first(val
* self
) {
375 val
* var
/* : nullable Object */;
376 val
* var1
/* : nullable Object */;
377 var1
= abstract_collection__Collection__first(self
);
382 /* method abstract_collection#Collection#has_all for (self: Collection[nullable Object], Collection[nullable Object]): Bool */
383 short int abstract_collection__Collection__has_all(val
* self
, val
* p0
) {
384 short int var
/* : Bool */;
385 short int var1
/* : Bool */;
388 const struct type
* type_struct
;
389 const char* var_class_name
;
390 val
* var_other
/* var other: Collection[nullable Object] */;
391 val
* var2
/* : Iterator[nullable Object] */;
392 short int var3
/* : Bool */;
393 val
* var4
/* : nullable Object */;
394 val
* var_x
/* var x: nullable Object */;
395 short int var5
/* : Bool */;
396 short int var6
/* : Bool */;
397 short int var7
/* : Bool */;
398 short int var8
/* : Bool */;
399 /* Covariant cast for argument 0 (other) <p0:Collection[nullable Object]> isa Collection[Collection#0] */
400 /* <p0:Collection[nullable Object]> isa Collection[Collection#0] */
401 type_struct
= self
->type
->resolution_table
->types
[COLOR_abstract_collection__Collectionabstract_collection__Collection_FT0
];
402 cltype
= type_struct
->color
;
403 idtype
= type_struct
->id
;
404 if(cltype
>= p0
->type
->table_size
) {
407 var1
= p0
->type
->type_table
[cltype
] == idtype
;
410 var_class_name
= p0
== NULL ?
"null" : p0
->type
->name
;
411 fprintf(stderr
, "Runtime error: Cast failed. Expected `%s`, got `%s`", "Collection[Collection#0]", var_class_name
);
412 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 125);
416 var2
= ((val
* (*)(val
*))(var_other
->class->vft
[COLOR_abstract_collection__Collection__iterator
]))(var_other
) /* iterator on <var_other:Collection[nullable Object]>*/;
418 var3
= ((short int (*)(val
*))(var2
->class->vft
[COLOR_abstract_collection__Iterator__is_ok
]))(var2
) /* is_ok on <var2:Iterator[nullable Object]>*/;
420 var4
= ((val
* (*)(val
*))(var2
->class->vft
[COLOR_abstract_collection__Iterator__item
]))(var2
) /* item on <var2:Iterator[nullable Object]>*/;
422 var5
= ((short int (*)(val
*, val
*))(self
->class->vft
[COLOR_abstract_collection__Collection__has
]))(self
, var_x
) /* has on <self:Collection[nullable Object]>*/;
430 CONTINUE_label
: (void)0;
431 ((void (*)(val
*))(var2
->class->vft
[COLOR_abstract_collection__Iterator__next
]))(var2
) /* next on <var2:Iterator[nullable Object]>*/;
433 BREAK_label
: (void)0;
440 /* method abstract_collection#Collection#has_all for (self: Object, Collection[nullable Object]): Bool */
441 short int VIRTUAL_abstract_collection__Collection__has_all(val
* self
, val
* p0
) {
442 short int var
/* : Bool */;
443 short int var1
/* : Bool */;
444 var1
= abstract_collection__Collection__has_all(self
, p0
);
449 /* method abstract_collection#Iterator#item for (self: Iterator[nullable Object]): nullable Object */
450 val
* abstract_collection__Iterator__item(val
* self
) {
451 val
* var
/* : nullable Object */;
452 const char* var_class_name
;
453 var_class_name
= self
== NULL ?
"null" : self
->type
->name
;
454 fprintf(stderr
, "Runtime error: Abstract method `%s` called on `%s`", "item", var_class_name
);
455 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 141);
460 /* method abstract_collection#Iterator#item for (self: Object): nullable Object */
461 val
* VIRTUAL_abstract_collection__Iterator__item(val
* self
) {
462 val
* var
/* : nullable Object */;
463 val
* var1
/* : nullable Object */;
464 var1
= abstract_collection__Iterator__item(self
);
469 /* method abstract_collection#Iterator#next for (self: Iterator[nullable Object]) */
470 void abstract_collection__Iterator__next(val
* self
) {
471 const char* var_class_name
;
472 var_class_name
= self
== NULL ?
"null" : self
->type
->name
;
473 fprintf(stderr
, "Runtime error: Abstract method `%s` called on `%s`", "next", var_class_name
);
474 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 145);
478 /* method abstract_collection#Iterator#next for (self: Object) */
479 void VIRTUAL_abstract_collection__Iterator__next(val
* self
) {
480 abstract_collection__Iterator__next(self
);
483 /* method abstract_collection#Iterator#is_ok for (self: Iterator[nullable Object]): Bool */
484 short int abstract_collection__Iterator__is_ok(val
* self
) {
485 short int var
/* : Bool */;
486 const char* var_class_name
;
487 var_class_name
= self
== NULL ?
"null" : self
->type
->name
;
488 fprintf(stderr
, "Runtime error: Abstract method `%s` called on `%s`", "is_ok", var_class_name
);
489 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 149);
494 /* method abstract_collection#Iterator#is_ok for (self: Object): Bool */
495 short int VIRTUAL_abstract_collection__Iterator__is_ok(val
* self
) {
496 short int var
/* : Bool */;
497 short int var1
/* : Bool */;
498 var1
= abstract_collection__Iterator__is_ok(self
);
503 /* method abstract_collection#Container#first for (self: Container[nullable Object]): nullable Object */
504 val
* abstract_collection__Container__first(val
* self
) {
505 val
* var
/* : nullable Object */;
506 val
* var1
/* : nullable Object */;
507 var1
= self
->attrs
[COLOR_abstract_collection__Container___item
].val
; /* _item on <self:Container[nullable Object]> */
513 /* method abstract_collection#Container#first for (self: Object): nullable Object */
514 val
* VIRTUAL_abstract_collection__Container__first(val
* self
) {
515 val
* var
/* : nullable Object */;
516 val
* var1
/* : nullable Object */;
517 var1
= abstract_collection__Container__first(self
);
522 /* method abstract_collection#Container#is_empty for (self: Container[nullable Object]): Bool */
523 short int abstract_collection__Container__is_empty(val
* self
) {
524 short int var
/* : Bool */;
525 short int var1
/* : Bool */;
532 /* method abstract_collection#Container#is_empty for (self: Object): Bool */
533 short int VIRTUAL_abstract_collection__Container__is_empty(val
* self
) {
534 short int var
/* : Bool */;
535 short int var1
/* : Bool */;
536 var1
= abstract_collection__Container__is_empty(self
);
541 /* method abstract_collection#Container#length for (self: Container[nullable Object]): Int */
542 long abstract_collection__Container__length(val
* self
) {
543 long var
/* : Int */;
544 long var1
/* : Int */;
551 /* method abstract_collection#Container#length for (self: Object): Int */
552 long VIRTUAL_abstract_collection__Container__length(val
* self
) {
553 long var
/* : Int */;
554 long var1
/* : Int */;
555 var1
= abstract_collection__Container__length(self
);
560 /* method abstract_collection#Container#has for (self: Container[nullable Object], nullable Object): Bool */
561 short int abstract_collection__Container__has(val
* self
, val
* p0
) {
562 short int var
/* : Bool */;
563 short int var1
/* : Bool */;
566 const struct type
* type_struct
;
567 short int is_nullable
;
568 const char* var_class_name
;
569 val
* var_an_item
/* var an_item: nullable Object */;
570 val
* var2
/* : nullable Object */;
571 short int var3
/* : Bool */;
572 /* Covariant cast for argument 0 (an_item) <p0:nullable Object> isa Collection#0 */
573 /* <p0:nullable Object> isa Collection#0 */
574 type_struct
= self
->type
->resolution_table
->types
[COLOR_abstract_collection__Collection_FT0
];
575 cltype
= type_struct
->color
;
576 idtype
= type_struct
->id
;
577 is_nullable
= type_struct
->is_nullable
;
581 if(cltype
>= p0
->type
->table_size
) {
584 var1
= p0
->type
->type_table
[cltype
] == idtype
;
588 var_class_name
= p0
== NULL ?
"null" : p0
->type
->name
;
589 fprintf(stderr
, "Runtime error: Cast failed. Expected `%s`, got `%s`", "Collection#0", var_class_name
);
590 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 164);
594 var2
= self
->attrs
[COLOR_abstract_collection__Container___item
].val
; /* _item on <self:Container[nullable Object]> */
596 var3
= (var_an_item
== NULL
);
598 var3
= ((short int (*)(val
*, val
*))(var2
->class->vft
[COLOR_kernel__Object___61d_61d
]))(var2
, var_an_item
) /* == on <var2:nullable Object>*/;
605 /* method abstract_collection#Container#has for (self: Object, nullable Object): Bool */
606 short int VIRTUAL_abstract_collection__Container__has(val
* self
, val
* p0
) {
607 short int var
/* : Bool */;
608 short int var1
/* : Bool */;
609 var1
= abstract_collection__Container__has(self
, p0
);
614 /* method abstract_collection#Container#has_only for (self: Container[nullable Object], nullable Object): Bool */
615 short int abstract_collection__Container__has_only(val
* self
, val
* p0
) {
616 short int var
/* : Bool */;
617 short int var1
/* : Bool */;
620 const struct type
* type_struct
;
621 short int is_nullable
;
622 const char* var_class_name
;
623 val
* var_an_item
/* var an_item: nullable Object */;
624 val
* var2
/* : nullable Object */;
625 short int var3
/* : Bool */;
626 /* Covariant cast for argument 0 (an_item) <p0:nullable Object> isa Collection#0 */
627 /* <p0:nullable Object> isa Collection#0 */
628 type_struct
= self
->type
->resolution_table
->types
[COLOR_abstract_collection__Collection_FT0
];
629 cltype
= type_struct
->color
;
630 idtype
= type_struct
->id
;
631 is_nullable
= type_struct
->is_nullable
;
635 if(cltype
>= p0
->type
->table_size
) {
638 var1
= p0
->type
->type_table
[cltype
] == idtype
;
642 var_class_name
= p0
== NULL ?
"null" : p0
->type
->name
;
643 fprintf(stderr
, "Runtime error: Cast failed. Expected `%s`, got `%s`", "Collection#0", var_class_name
);
644 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 166);
648 var2
= self
->attrs
[COLOR_abstract_collection__Container___item
].val
; /* _item on <self:Container[nullable Object]> */
650 var3
= (var_an_item
== NULL
);
652 var3
= ((short int (*)(val
*, val
*))(var2
->class->vft
[COLOR_kernel__Object___61d_61d
]))(var2
, var_an_item
) /* == on <var2:nullable Object>*/;
659 /* method abstract_collection#Container#has_only for (self: Object, nullable Object): Bool */
660 short int VIRTUAL_abstract_collection__Container__has_only(val
* self
, val
* p0
) {
661 short int var
/* : Bool */;
662 short int var1
/* : Bool */;
663 var1
= abstract_collection__Container__has_only(self
, p0
);
668 /* method abstract_collection#Container#count for (self: Container[nullable Object], nullable Object): Int */
669 long abstract_collection__Container__count(val
* self
, val
* p0
) {
670 long var
/* : Int */;
671 short int var1
/* : Bool */;
674 const struct type
* type_struct
;
675 short int is_nullable
;
676 const char* var_class_name
;
677 val
* var_an_item
/* var an_item: nullable Object */;
678 val
* var2
/* : nullable Object */;
679 short int var3
/* : Bool */;
680 long var4
/* : Int */;
681 long var5
/* : Int */;
682 /* Covariant cast for argument 0 (an_item) <p0:nullable Object> isa Collection#0 */
683 /* <p0:nullable Object> isa Collection#0 */
684 type_struct
= self
->type
->resolution_table
->types
[COLOR_abstract_collection__Collection_FT0
];
685 cltype
= type_struct
->color
;
686 idtype
= type_struct
->id
;
687 is_nullable
= type_struct
->is_nullable
;
691 if(cltype
>= p0
->type
->table_size
) {
694 var1
= p0
->type
->type_table
[cltype
] == idtype
;
698 var_class_name
= p0
== NULL ?
"null" : p0
->type
->name
;
699 fprintf(stderr
, "Runtime error: Cast failed. Expected `%s`, got `%s`", "Collection#0", var_class_name
);
700 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 168);
704 var2
= self
->attrs
[COLOR_abstract_collection__Container___item
].val
; /* _item on <self:Container[nullable Object]> */
706 var3
= (var_an_item
== NULL
);
708 var3
= ((short int (*)(val
*, val
*))(var2
->class->vft
[COLOR_kernel__Object___61d_61d
]))(var2
, var_an_item
) /* == on <var2:nullable Object>*/;
722 /* method abstract_collection#Container#count for (self: Object, nullable Object): Int */
723 long VIRTUAL_abstract_collection__Container__count(val
* self
, val
* p0
) {
724 long var
/* : Int */;
725 long var1
/* : Int */;
726 var1
= abstract_collection__Container__count(self
, p0
);
731 /* method abstract_collection#Container#iterator for (self: Container[nullable Object]): Iterator[nullable Object] */
732 val
* abstract_collection__Container__iterator(val
* self
) {
733 val
* var
/* : Iterator[nullable Object] */;
734 val
* var1
/* : ContainerIterator[nullable Object] */;
735 var1
= NEW_abstract_collection__ContainerIterator(self
->type
->resolution_table
->types
[COLOR_abstract_collection__ContainerIteratorabstract_collection__Container_FT0
]);
736 ((void (*)(val
*, val
*))(var1
->class->vft
[COLOR_abstract_collection__ContainerIterator__init
]))(var1
, self
) /* init on <var1:ContainerIterator[nullable Object]>*/;
742 /* method abstract_collection#Container#iterator for (self: Object): Iterator[nullable Object] */
743 val
* VIRTUAL_abstract_collection__Container__iterator(val
* self
) {
744 val
* var
/* : Iterator[nullable Object] */;
745 val
* var1
/* : Iterator[nullable Object] */;
746 var1
= abstract_collection__Container__iterator(self
);
751 /* method abstract_collection#Container#init for (self: Container[nullable Object], nullable Object) */
752 void abstract_collection__Container__init(val
* self
, val
* p0
) {
753 short int var
/* : Bool */;
756 const struct type
* type_struct
;
757 short int is_nullable
;
758 const char* var_class_name
;
759 val
* var_e
/* var e: nullable Object */;
760 /* Covariant cast for argument 0 (e) <p0:nullable Object> isa Container#0 */
761 /* <p0:nullable Object> isa Container#0 */
762 type_struct
= self
->type
->resolution_table
->types
[COLOR_abstract_collection__Container_FT0
];
763 cltype
= type_struct
->color
;
764 idtype
= type_struct
->id
;
765 is_nullable
= type_struct
->is_nullable
;
769 if(cltype
>= p0
->type
->table_size
) {
772 var
= p0
->type
->type_table
[cltype
] == idtype
;
776 var_class_name
= p0
== NULL ?
"null" : p0
->type
->name
;
777 fprintf(stderr
, "Runtime error: Cast failed. Expected `%s`, got `%s`", "Container#0", var_class_name
);
778 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 179);
782 self
->attrs
[COLOR_abstract_collection__Container___item
].val
= var_e
; /* _item on <self:Container[nullable Object]> */
785 /* method abstract_collection#Container#init for (self: Object, nullable Object) */
786 void VIRTUAL_abstract_collection__Container__init(val
* self
, val
* p0
) {
787 abstract_collection__Container__init(self
, p0
);
790 /* method abstract_collection#Container#item for (self: Container[nullable Object]): nullable Object */
791 val
* abstract_collection__Container__item(val
* self
) {
792 val
* var
/* : nullable Object */;
793 val
* var1
/* : nullable Object */;
794 var1
= self
->attrs
[COLOR_abstract_collection__Container___item
].val
; /* _item on <self:Container[nullable Object]> */
799 /* method abstract_collection#Container#item for (self: Object): nullable Object */
800 val
* VIRTUAL_abstract_collection__Container__item(val
* self
) {
801 val
* var
/* : nullable Object */;
802 val
* var1
/* : nullable Object */;
803 var1
= abstract_collection__Container__item(self
);
808 /* method abstract_collection#Container#item= for (self: Container[nullable Object], nullable Object) */
809 void abstract_collection__Container__item_61d(val
* self
, val
* p0
) {
810 short int var
/* : Bool */;
813 const struct type
* type_struct
;
814 short int is_nullable
;
815 const char* var_class_name
;
816 /* Covariant cast for argument 0 (item) <p0:nullable Object> isa Container#0 */
817 /* <p0:nullable Object> isa Container#0 */
818 type_struct
= self
->type
->resolution_table
->types
[COLOR_abstract_collection__Container_FT0
];
819 cltype
= type_struct
->color
;
820 idtype
= type_struct
->id
;
821 is_nullable
= type_struct
->is_nullable
;
825 if(cltype
>= p0
->type
->table_size
) {
828 var
= p0
->type
->type_table
[cltype
] == idtype
;
832 var_class_name
= p0
== NULL ?
"null" : p0
->type
->name
;
833 fprintf(stderr
, "Runtime error: Cast failed. Expected `%s`, got `%s`", "Container#0", var_class_name
);
834 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 182);
837 self
->attrs
[COLOR_abstract_collection__Container___item
].val
= p0
; /* _item on <self:Container[nullable Object]> */
840 /* method abstract_collection#Container#item= for (self: Object, nullable Object) */
841 void VIRTUAL_abstract_collection__Container__item_61d(val
* self
, val
* p0
) {
842 abstract_collection__Container__item_61d(self
, p0
);
845 /* method abstract_collection#ContainerIterator#item for (self: ContainerIterator[nullable Object]): nullable Object */
846 val
* abstract_collection__ContainerIterator__item(val
* self
) {
847 val
* var
/* : nullable Object */;
848 val
* var1
/* : Container[nullable Object] */;
849 val
* var2
/* : nullable Object */;
850 var1
= self
->attrs
[COLOR_abstract_collection__ContainerIterator___container
].val
; /* _container on <self:ContainerIterator[nullable Object]> */
852 fprintf(stderr
, "Runtime error: %s", "Uninitialized attribute _container");
853 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 189);
856 var2
= ((val
* (*)(val
*))(var1
->class->vft
[COLOR_abstract_collection__Container__item
]))(var1
) /* item on <var1:Container[nullable Object]>*/;
862 /* method abstract_collection#ContainerIterator#item for (self: Object): nullable Object */
863 val
* VIRTUAL_abstract_collection__ContainerIterator__item(val
* self
) {
864 val
* var
/* : nullable Object */;
865 val
* var1
/* : nullable Object */;
866 var1
= abstract_collection__ContainerIterator__item(self
);
871 /* method abstract_collection#ContainerIterator#next for (self: ContainerIterator[nullable Object]) */
872 void abstract_collection__ContainerIterator__next(val
* self
) {
873 short int var
/* : Bool */;
875 self
->attrs
[COLOR_abstract_collection__ContainerIterator___is_ok
].s
= var
; /* _is_ok on <self:ContainerIterator[nullable Object]> */
878 /* method abstract_collection#ContainerIterator#next for (self: Object) */
879 void VIRTUAL_abstract_collection__ContainerIterator__next(val
* self
) {
880 abstract_collection__ContainerIterator__next(self
);
883 /* method abstract_collection#ContainerIterator#init for (self: ContainerIterator[nullable Object], Container[nullable Object]) */
884 void abstract_collection__ContainerIterator__init(val
* self
, val
* p0
) {
885 short int var
/* : Bool */;
888 const struct type
* type_struct
;
889 const char* var_class_name
;
890 val
* var_c
/* var c: Container[nullable Object] */;
891 /* Covariant cast for argument 0 (c) <p0:Container[nullable Object]> isa Container[ContainerIterator#0] */
892 /* <p0:Container[nullable Object]> isa Container[ContainerIterator#0] */
893 type_struct
= self
->type
->resolution_table
->types
[COLOR_abstract_collection__Containerabstract_collection__ContainerIterator_FT0
];
894 cltype
= type_struct
->color
;
895 idtype
= type_struct
->id
;
896 if(cltype
>= p0
->type
->table_size
) {
899 var
= p0
->type
->type_table
[cltype
] == idtype
;
902 var_class_name
= p0
== NULL ?
"null" : p0
->type
->name
;
903 fprintf(stderr
, "Runtime error: Cast failed. Expected `%s`, got `%s`", "Container[ContainerIterator#0]", var_class_name
);
904 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 193);
908 self
->attrs
[COLOR_abstract_collection__ContainerIterator___container
].val
= var_c
; /* _container on <self:ContainerIterator[nullable Object]> */
911 /* method abstract_collection#ContainerIterator#init for (self: Object, Container[nullable Object]) */
912 void VIRTUAL_abstract_collection__ContainerIterator__init(val
* self
, val
* p0
) {
913 abstract_collection__ContainerIterator__init(self
, p0
);
916 /* method abstract_collection#ContainerIterator#is_ok for (self: ContainerIterator[nullable Object]): Bool */
917 short int abstract_collection__ContainerIterator__is_ok(val
* self
) {
918 short int var
/* : Bool */;
919 short int var1
/* : Bool */;
920 var1
= self
->attrs
[COLOR_abstract_collection__ContainerIterator___is_ok
].s
; /* _is_ok on <self:ContainerIterator[nullable Object]> */
925 /* method abstract_collection#ContainerIterator#is_ok for (self: Object): Bool */
926 short int VIRTUAL_abstract_collection__ContainerIterator__is_ok(val
* self
) {
927 short int var
/* : Bool */;
928 short int var1
/* : Bool */;
929 var1
= abstract_collection__ContainerIterator__is_ok(self
);
934 /* method abstract_collection#RemovableCollection#clear for (self: RemovableCollection[nullable Object]) */
935 void abstract_collection__RemovableCollection__clear(val
* self
) {
936 const char* var_class_name
;
937 var_class_name
= self
== NULL ?
"null" : self
->type
->name
;
938 fprintf(stderr
, "Runtime error: Abstract method `%s` called on `%s`", "clear", var_class_name
);
939 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 203);
943 /* method abstract_collection#RemovableCollection#clear for (self: Object) */
944 void VIRTUAL_abstract_collection__RemovableCollection__clear(val
* self
) {
945 abstract_collection__RemovableCollection__clear(self
);
948 /* method abstract_collection#RemovableCollection#remove for (self: RemovableCollection[nullable Object], nullable Object) */
949 void abstract_collection__RemovableCollection__remove(val
* self
, val
* p0
) {
950 short int var
/* : Bool */;
953 const struct type
* type_struct
;
954 short int is_nullable
;
955 const char* var_class_name
;
956 const char* var_class_name1
;
957 /* Covariant cast for argument 0 (item) <p0:nullable Object> isa RemovableCollection#0 */
958 /* <p0:nullable Object> isa RemovableCollection#0 */
959 type_struct
= self
->type
->resolution_table
->types
[COLOR_abstract_collection__RemovableCollection_FT0
];
960 cltype
= type_struct
->color
;
961 idtype
= type_struct
->id
;
962 is_nullable
= type_struct
->is_nullable
;
966 if(cltype
>= p0
->type
->table_size
) {
969 var
= p0
->type
->type_table
[cltype
] == idtype
;
973 var_class_name
= p0
== NULL ?
"null" : p0
->type
->name
;
974 fprintf(stderr
, "Runtime error: Cast failed. Expected `%s`, got `%s`", "RemovableCollection#0", var_class_name
);
975 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 206);
978 var_class_name1
= self
== NULL ?
"null" : self
->type
->name
;
979 fprintf(stderr
, "Runtime error: Abstract method `%s` called on `%s`", "remove", var_class_name1
);
980 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 206);
984 /* method abstract_collection#RemovableCollection#remove for (self: Object, nullable Object) */
985 void VIRTUAL_abstract_collection__RemovableCollection__remove(val
* self
, val
* p0
) {
986 abstract_collection__RemovableCollection__remove(self
, p0
);
989 /* method abstract_collection#RemovableCollection#remove_all for (self: RemovableCollection[nullable Object], nullable Object) */
990 void abstract_collection__RemovableCollection__remove_all(val
* self
, val
* p0
) {
991 short int var
/* : Bool */;
994 const struct type
* type_struct
;
995 short int is_nullable
;
996 const char* var_class_name
;
997 val
* var_item
/* var item: nullable Object */;
998 short int var1
/* : Bool */;
999 /* Covariant cast for argument 0 (item) <p0:nullable Object> isa RemovableCollection#0 */
1000 /* <p0:nullable Object> isa RemovableCollection#0 */
1001 type_struct
= self
->type
->resolution_table
->types
[COLOR_abstract_collection__RemovableCollection_FT0
];
1002 cltype
= type_struct
->color
;
1003 idtype
= type_struct
->id
;
1004 is_nullable
= type_struct
->is_nullable
;
1008 if(cltype
>= p0
->type
->table_size
) {
1011 var
= p0
->type
->type_table
[cltype
] == idtype
;
1015 var_class_name
= p0
== NULL ?
"null" : p0
->type
->name
;
1016 fprintf(stderr
, "Runtime error: Cast failed. Expected `%s`, got `%s`", "RemovableCollection#0", var_class_name
);
1017 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 209);
1022 var1
= ((short int (*)(val
*, val
*))(self
->class->vft
[COLOR_abstract_collection__Collection__has
]))(self
, var_item
) /* has on <self:RemovableCollection[nullable Object]>*/;
1024 ((void (*)(val
*, val
*))(self
->class->vft
[COLOR_abstract_collection__RemovableCollection__remove
]))(self
, var_item
) /* remove on <self:RemovableCollection[nullable Object]>*/;
1025 CONTINUE_label
: (void)0;
1027 BREAK_label
: (void)0;
1030 /* method abstract_collection#RemovableCollection#remove_all for (self: Object, nullable Object) */
1031 void VIRTUAL_abstract_collection__RemovableCollection__remove_all(val
* self
, val
* p0
) {
1032 abstract_collection__RemovableCollection__remove_all(self
, p0
);
1035 /* method abstract_collection#SimpleCollection#add for (self: SimpleCollection[nullable Object], nullable Object) */
1036 void abstract_collection__SimpleCollection__add(val
* self
, val
* p0
) {
1037 short int var
/* : Bool */;
1040 const struct type
* type_struct
;
1041 short int is_nullable
;
1042 const char* var_class_name
;
1043 const char* var_class_name1
;
1044 /* Covariant cast for argument 0 (item) <p0:nullable Object> isa SimpleCollection#0 */
1045 /* <p0:nullable Object> isa SimpleCollection#0 */
1046 type_struct
= self
->type
->resolution_table
->types
[COLOR_abstract_collection__SimpleCollection_FT0
];
1047 cltype
= type_struct
->color
;
1048 idtype
= type_struct
->id
;
1049 is_nullable
= type_struct
->is_nullable
;
1053 if(cltype
>= p0
->type
->table_size
) {
1056 var
= p0
->type
->type_table
[cltype
] == idtype
;
1060 var_class_name
= p0
== NULL ?
"null" : p0
->type
->name
;
1061 fprintf(stderr
, "Runtime error: Cast failed. Expected `%s`, got `%s`", "SimpleCollection#0", var_class_name
);
1062 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 216);
1065 var_class_name1
= self
== NULL ?
"null" : self
->type
->name
;
1066 fprintf(stderr
, "Runtime error: Abstract method `%s` called on `%s`", "add", var_class_name1
);
1067 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 216);
1071 /* method abstract_collection#SimpleCollection#add for (self: Object, nullable Object) */
1072 void VIRTUAL_abstract_collection__SimpleCollection__add(val
* self
, val
* p0
) {
1073 abstract_collection__SimpleCollection__add(self
, p0
);
1076 /* method abstract_collection#SimpleCollection#add_all for (self: SimpleCollection[nullable Object], Collection[nullable Object]) */
1077 void abstract_collection__SimpleCollection__add_all(val
* self
, val
* p0
) {
1078 short int var
/* : Bool */;
1081 const struct type
* type_struct
;
1082 const char* var_class_name
;
1083 val
* var_coll
/* var coll: Collection[nullable Object] */;
1084 val
* var1
/* : Iterator[nullable Object] */;
1085 short int var2
/* : Bool */;
1086 val
* var3
/* : nullable Object */;
1087 val
* var_i
/* var i: nullable Object */;
1088 /* Covariant cast for argument 0 (coll) <p0:Collection[nullable Object]> isa Collection[SimpleCollection#0] */
1089 /* <p0:Collection[nullable Object]> isa Collection[SimpleCollection#0] */
1090 type_struct
= self
->type
->resolution_table
->types
[COLOR_abstract_collection__Collectionabstract_collection__SimpleCollection_FT0
];
1091 cltype
= type_struct
->color
;
1092 idtype
= type_struct
->id
;
1093 if(cltype
>= p0
->type
->table_size
) {
1096 var
= p0
->type
->type_table
[cltype
] == idtype
;
1099 var_class_name
= p0
== NULL ?
"null" : p0
->type
->name
;
1100 fprintf(stderr
, "Runtime error: Cast failed. Expected `%s`, got `%s`", "Collection[SimpleCollection#0]", var_class_name
);
1101 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 220);
1105 var1
= ((val
* (*)(val
*))(var_coll
->class->vft
[COLOR_abstract_collection__Collection__iterator
]))(var_coll
) /* iterator on <var_coll:Collection[nullable Object]>*/;
1107 var2
= ((short int (*)(val
*))(var1
->class->vft
[COLOR_abstract_collection__Iterator__is_ok
]))(var1
) /* is_ok on <var1:Iterator[nullable Object]>*/;
1109 var3
= ((val
* (*)(val
*))(var1
->class->vft
[COLOR_abstract_collection__Iterator__item
]))(var1
) /* item on <var1:Iterator[nullable Object]>*/;
1111 ((void (*)(val
*, val
*))(self
->class->vft
[COLOR_abstract_collection__SimpleCollection__add
]))(self
, var_i
) /* add on <self:SimpleCollection[nullable Object]>*/;
1112 CONTINUE_label
: (void)0;
1113 ((void (*)(val
*))(var1
->class->vft
[COLOR_abstract_collection__Iterator__next
]))(var1
) /* next on <var1:Iterator[nullable Object]>*/;
1115 BREAK_label
: (void)0;
1118 /* method abstract_collection#SimpleCollection#add_all for (self: Object, Collection[nullable Object]) */
1119 void VIRTUAL_abstract_collection__SimpleCollection__add_all(val
* self
, val
* p0
) {
1120 abstract_collection__SimpleCollection__add_all(self
, p0
);
1123 /* method abstract_collection#Set#has_only for (self: Set[Object], Object): Bool */
1124 short int abstract_collection__Set__has_only(val
* self
, val
* p0
) {
1125 short int var
/* : Bool */;
1126 short int var1
/* : Bool */;
1129 const struct type
* type_struct
;
1130 const char* var_class_name
;
1131 val
* var_item
/* var item: Object */;
1132 long var2
/* : Int */;
1133 long var_l
/* var l: Int */;
1134 long var3
/* : Int */;
1135 short int var4
/* : Bool */;
1136 short int var6
/* : Bool */;
1137 short int var7
/* : Bool */;
1138 long var8
/* : Int */;
1139 short int var9
/* : Bool */;
1140 short int var11
/* : Bool */;
1141 short int var12
/* : Bool */;
1142 short int var13
/* : Bool */;
1143 /* Covariant cast for argument 0 (item) <p0:Object> isa Collection#0 */
1144 /* <p0:Object> isa Collection#0 */
1145 type_struct
= self
->type
->resolution_table
->types
[COLOR_abstract_collection__Collection_FT0
];
1146 cltype
= type_struct
->color
;
1147 idtype
= type_struct
->id
;
1148 if(cltype
>= p0
->type
->table_size
) {
1151 var1
= p0
->type
->type_table
[cltype
] == idtype
;
1154 var_class_name
= p0
== NULL ?
"null" : p0
->type
->name
;
1155 fprintf(stderr
, "Runtime error: Cast failed. Expected `%s`, got `%s`", "Collection#0", var_class_name
);
1156 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 236);
1160 var2
= ((long (*)(val
*))(self
->class->vft
[COLOR_abstract_collection__Collection__length
]))(self
) /* length on <self:Set[Object]>*/;
1163 { /* Inline kernel#Int#== (var_l,var3) */
1164 var6
= var_l
== var3
;
1170 var7
= ((short int (*)(val
*, val
*))(self
->class->vft
[COLOR_abstract_collection__Collection__has
]))(self
, var_item
) /* has on <self:Set[Object]>*/;
1175 { /* Inline kernel#Int#== (var_l,var8) */
1176 var11
= var_l
== var8
;
1179 RET_LABEL10
:(void)0;
1194 /* method abstract_collection#Set#has_only for (self: Object, nullable Object): Bool */
1195 short int VIRTUAL_abstract_collection__Set__has_only(val
* self
, val
* p0
) {
1196 short int var
/* : Bool */;
1197 short int var1
/* : Bool */;
1198 var1
= abstract_collection__Set__has_only(self
, p0
);
1203 /* method abstract_collection#Set#count for (self: Set[Object], Object): Int */
1204 long abstract_collection__Set__count(val
* self
, val
* p0
) {
1205 long var
/* : Int */;
1206 short int var1
/* : Bool */;
1209 const struct type
* type_struct
;
1210 const char* var_class_name
;
1211 val
* var_item
/* var item: Object */;
1212 short int var2
/* : Bool */;
1213 long var3
/* : Int */;
1214 long var4
/* : Int */;
1215 /* Covariant cast for argument 0 (item) <p0:Object> isa Collection#0 */
1216 /* <p0:Object> isa Collection#0 */
1217 type_struct
= self
->type
->resolution_table
->types
[COLOR_abstract_collection__Collection_FT0
];
1218 cltype
= type_struct
->color
;
1219 idtype
= type_struct
->id
;
1220 if(cltype
>= p0
->type
->table_size
) {
1223 var1
= p0
->type
->type_table
[cltype
] == idtype
;
1226 var_class_name
= p0
== NULL ?
"null" : p0
->type
->name
;
1227 fprintf(stderr
, "Runtime error: Cast failed. Expected `%s`, got `%s`", "Collection#0", var_class_name
);
1228 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 248);
1232 var2
= ((short int (*)(val
*, val
*))(self
->class->vft
[COLOR_abstract_collection__Collection__has
]))(self
, var_item
) /* has on <self:Set[Object]>*/;
1245 /* method abstract_collection#Set#count for (self: Object, nullable Object): Int */
1246 long VIRTUAL_abstract_collection__Set__count(val
* self
, val
* p0
) {
1247 long var
/* : Int */;
1248 long var1
/* : Int */;
1249 var1
= abstract_collection__Set__count(self
, p0
);
1254 /* method abstract_collection#Set#remove_all for (self: Set[Object], Object) */
1255 void abstract_collection__Set__remove_all(val
* self
, val
* p0
) {
1256 short int var
/* : Bool */;
1259 const struct type
* type_struct
;
1260 const char* var_class_name
;
1261 val
* var_item
/* var item: Object */;
1262 /* Covariant cast for argument 0 (item) <p0:Object> isa RemovableCollection#0 */
1263 /* <p0:Object> isa RemovableCollection#0 */
1264 type_struct
= self
->type
->resolution_table
->types
[COLOR_abstract_collection__RemovableCollection_FT0
];
1265 cltype
= type_struct
->color
;
1266 idtype
= type_struct
->id
;
1267 if(cltype
>= p0
->type
->table_size
) {
1270 var
= p0
->type
->type_table
[cltype
] == idtype
;
1273 var_class_name
= p0
== NULL ?
"null" : p0
->type
->name
;
1274 fprintf(stderr
, "Runtime error: Cast failed. Expected `%s`, got `%s`", "RemovableCollection#0", var_class_name
);
1275 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 258);
1279 ((void (*)(val
*, val
*))(self
->class->vft
[COLOR_abstract_collection__RemovableCollection__remove
]))(self
, var_item
) /* remove on <self:Set[Object]>*/;
1282 /* method abstract_collection#Set#remove_all for (self: Object, nullable Object) */
1283 void VIRTUAL_abstract_collection__Set__remove_all(val
* self
, val
* p0
) {
1284 abstract_collection__Set__remove_all(self
, p0
);
1287 /* method abstract_collection#Set#== for (self: Set[Object], nullable Object): Bool */
1288 short int abstract_collection__Set___61d_61d(val
* self
, val
* p0
) {
1289 short int var
/* : Bool */;
1290 val
* var_other
/* var other: nullable Object */;
1291 short int var1
/* : Bool */;
1294 short int var2
/* : Bool */;
1295 short int var3
/* : Bool */;
1296 long var4
/* : Int */;
1297 long var5
/* : Int */;
1298 short int var6
/* : Bool */;
1299 short int var8
/* : Bool */;
1300 short int var9
/* : Bool */;
1301 short int var10
/* : Bool */;
1302 short int var11
/* : Bool */;
1305 const struct type
* type_struct
;
1306 const char* var_class_name
;
1307 short int var14
/* : Bool */;
1309 /* <var_other:nullable Object> isa Set[Object] */
1310 cltype
= type_abstract_collection__Setkernel__Object
.color
;
1311 idtype
= type_abstract_collection__Setkernel__Object
.id
;
1312 if(var_other
== NULL
) {
1315 if(cltype
>= var_other
->type
->table_size
) {
1318 var1
= var_other
->type
->type_table
[cltype
] == idtype
;
1328 var4
= ((long (*)(val
*))(var_other
->class->vft
[COLOR_abstract_collection__Collection__length
]))(var_other
) /* length on <var_other:nullable Object(Set[Object])>*/;
1329 var5
= ((long (*)(val
*))(self
->class->vft
[COLOR_abstract_collection__Collection__length
]))(self
) /* length on <self:Set[Object]>*/;
1330 { /* Inline kernel#Int#!= (var4,var5) */
1331 var8
= var4
== var5
;
1343 /* <var_other:nullable Object(Set[Object])> isa Collection[Set#0] */
1344 type_struct
= self
->type
->resolution_table
->types
[COLOR_abstract_collection__Collectionabstract_collection__Set_FT0
];
1345 cltype12
= type_struct
->color
;
1346 idtype13
= type_struct
->id
;
1347 if(cltype12
>= var_other
->type
->table_size
) {
1350 var11
= var_other
->type
->type_table
[cltype12
] == idtype13
;
1353 var_class_name
= var_other
== NULL ?
"null" : var_other
->type
->name
;
1354 fprintf(stderr
, "Runtime error: Cast failed. Expected `%s`, got `%s`", "Collection[Set#0]", var_class_name
);
1355 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 266);
1358 var14
= ((short int (*)(val
*, val
*))(self
->class->vft
[COLOR_abstract_collection__Collection__has_all
]))(self
, var_other
) /* has_all on <self:Set[Object]>*/;
1364 /* method abstract_collection#Set#== for (self: Object, nullable Object): Bool */
1365 short int VIRTUAL_abstract_collection__Set___61d_61d(val
* self
, val
* p0
) {
1366 short int var
/* : Bool */;
1367 short int var1
/* : Bool */;
1368 var1
= abstract_collection__Set___61d_61d(self
, p0
);
1373 /* method abstract_collection#Set#hash for (self: Set[Object]): Int */
1374 long abstract_collection__Set__hash(val
* self
) {
1375 long var
/* : Int */;
1376 long var1
/* : Int */;
1377 long var_res
/* var res: Int */;
1378 val
* var2
/* : Iterator[nullable Object] */;
1379 short int var3
/* : Bool */;
1380 val
* var4
/* : nullable Object */;
1381 val
* var_e
/* var e: Object */;
1382 long var5
/* : Int */;
1383 long var6
/* : Int */;
1384 long var8
/* : Int */;
1387 var2
= ((val
* (*)(val
*))(self
->class->vft
[COLOR_abstract_collection__Collection__iterator
]))(self
) /* iterator on <self:Set[Object]>*/;
1389 var3
= ((short int (*)(val
*))(var2
->class->vft
[COLOR_abstract_collection__Iterator__is_ok
]))(var2
) /* is_ok on <var2:Iterator[nullable Object]>*/;
1391 var4
= ((val
* (*)(val
*))(var2
->class->vft
[COLOR_abstract_collection__Iterator__item
]))(var2
) /* item on <var2:Iterator[nullable Object]>*/;
1393 var5
= kernel__Int__hash(var_res
);
1394 { /* Inline kernel#Int#+ (var_res,var5) */
1395 var8
= var_res
+ var5
;
1401 CONTINUE_label
: (void)0;
1402 ((void (*)(val
*))(var2
->class->vft
[COLOR_abstract_collection__Iterator__next
]))(var2
) /* next on <var2:Iterator[nullable Object]>*/;
1404 BREAK_label
: (void)0;
1410 /* method abstract_collection#Set#hash for (self: Object): Int */
1411 long VIRTUAL_abstract_collection__Set__hash(val
* self
) {
1412 long var
/* : Int */;
1413 long var1
/* : Int */;
1414 var1
= abstract_collection__Set__hash(self
);
1419 /* method abstract_collection#MapRead#[] for (self: MapRead[Object, nullable Object], Object): nullable Object */
1420 val
* abstract_collection__MapRead___91d_93d(val
* self
, val
* p0
) {
1421 val
* var
/* : nullable Object */;
1422 short int var1
/* : Bool */;
1425 const struct type
* type_struct
;
1426 const char* var_class_name
;
1427 const char* var_class_name2
;
1428 /* Covariant cast for argument 0 (key) <p0:Object> isa MapRead#0 */
1429 /* <p0:Object> isa MapRead#0 */
1430 type_struct
= self
->type
->resolution_table
->types
[COLOR_abstract_collection__MapRead_FT0
];
1431 cltype
= type_struct
->color
;
1432 idtype
= type_struct
->id
;
1433 if(cltype
>= p0
->type
->table_size
) {
1436 var1
= p0
->type
->type_table
[cltype
] == idtype
;
1439 var_class_name
= p0
== NULL ?
"null" : p0
->type
->name
;
1440 fprintf(stderr
, "Runtime error: Cast failed. Expected `%s`, got `%s`", "MapRead#0", var_class_name
);
1441 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 280);
1444 var_class_name2
= self
== NULL ?
"null" : self
->type
->name
;
1445 fprintf(stderr
, "Runtime error: Abstract method `%s` called on `%s`", "[]", var_class_name2
);
1446 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 280);
1451 /* method abstract_collection#MapRead#[] for (self: Object, Object): nullable Object */
1452 val
* VIRTUAL_abstract_collection__MapRead___91d_93d(val
* self
, val
* p0
) {
1453 val
* var
/* : nullable Object */;
1454 val
* var1
/* : nullable Object */;
1455 var1
= abstract_collection__MapRead___91d_93d(self
, p0
);
1460 /* method abstract_collection#MapRead#get_or_default for (self: MapRead[Object, nullable Object], Object, nullable Object): nullable Object */
1461 val
* abstract_collection__MapRead__get_or_default(val
* self
, val
* p0
, val
* p1
) {
1462 val
* var
/* : nullable Object */;
1463 short int var1
/* : Bool */;
1466 const struct type
* type_struct
;
1467 const char* var_class_name
;
1468 short int var2
/* : Bool */;
1471 const struct type
* type_struct5
;
1472 short int is_nullable
;
1473 const char* var_class_name6
;
1474 val
* var_key
/* var key: Object */;
1475 val
* var_default
/* var default: nullable Object */;
1476 short int var7
/* : Bool */;
1477 val
* var8
/* : nullable Object */;
1478 /* Covariant cast for argument 0 (key) <p0:Object> isa MapRead#0 */
1479 /* <p0:Object> isa MapRead#0 */
1480 type_struct
= self
->type
->resolution_table
->types
[COLOR_abstract_collection__MapRead_FT0
];
1481 cltype
= type_struct
->color
;
1482 idtype
= type_struct
->id
;
1483 if(cltype
>= p0
->type
->table_size
) {
1486 var1
= p0
->type
->type_table
[cltype
] == idtype
;
1489 var_class_name
= p0
== NULL ?
"null" : p0
->type
->name
;
1490 fprintf(stderr
, "Runtime error: Cast failed. Expected `%s`, got `%s`", "MapRead#0", var_class_name
);
1491 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 283);
1494 /* Covariant cast for argument 1 (default) <p1:nullable Object> isa MapRead#1 */
1495 /* <p1:nullable Object> isa MapRead#1 */
1496 type_struct5
= self
->type
->resolution_table
->types
[COLOR_abstract_collection__MapRead_FT1
];
1497 cltype3
= type_struct5
->color
;
1498 idtype4
= type_struct5
->id
;
1499 is_nullable
= type_struct5
->is_nullable
;
1503 if(cltype3
>= p1
->type
->table_size
) {
1506 var2
= p1
->type
->type_table
[cltype3
] == idtype4
;
1510 var_class_name6
= p1
== NULL ?
"null" : p1
->type
->name
;
1511 fprintf(stderr
, "Runtime error: Cast failed. Expected `%s`, got `%s`", "MapRead#1", var_class_name6
);
1512 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 283);
1517 var7
= ((short int (*)(val
*, val
*))(self
->class->vft
[COLOR_abstract_collection__MapRead__has_key
]))(self
, var_key
) /* has_key on <self:MapRead[Object, nullable Object]>*/;
1519 var8
= ((val
* (*)(val
*, val
*))(self
->class->vft
[COLOR_abstract_collection__MapRead___91d_93d
]))(self
, var_key
) /* [] on <self:MapRead[Object, nullable Object]>*/;
1529 /* method abstract_collection#MapRead#get_or_default for (self: Object, Object, nullable Object): nullable Object */
1530 val
* VIRTUAL_abstract_collection__MapRead__get_or_default(val
* self
, val
* p0
, val
* p1
) {
1531 val
* var
/* : nullable Object */;
1532 val
* var1
/* : nullable Object */;
1533 var1
= abstract_collection__MapRead__get_or_default(self
, p0
, p1
);
1538 /* method abstract_collection#MapRead#has_key for (self: MapRead[Object, nullable Object], Object): Bool */
1539 short int abstract_collection__MapRead__has_key(val
* self
, val
* p0
) {
1540 short int var
/* : Bool */;
1541 short int var1
/* : Bool */;
1544 const struct type
* type_struct
;
1545 const char* var_class_name
;
1546 val
* var_key
/* var key: Object */;
1547 val
* var2
/* : Collection[Object] */;
1548 short int var3
/* : Bool */;
1549 /* Covariant cast for argument 0 (key) <p0:Object> isa MapRead#0 */
1550 /* <p0:Object> isa MapRead#0 */
1551 type_struct
= self
->type
->resolution_table
->types
[COLOR_abstract_collection__MapRead_FT0
];
1552 cltype
= type_struct
->color
;
1553 idtype
= type_struct
->id
;
1554 if(cltype
>= p0
->type
->table_size
) {
1557 var1
= p0
->type
->type_table
[cltype
] == idtype
;
1560 var_class_name
= p0
== NULL ?
"null" : p0
->type
->name
;
1561 fprintf(stderr
, "Runtime error: Cast failed. Expected `%s`, got `%s`", "MapRead#0", var_class_name
);
1562 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 290);
1566 var2
= ((val
* (*)(val
*))(self
->class->vft
[COLOR_abstract_collection__MapRead__keys
]))(self
) /* keys on <self:MapRead[Object, nullable Object]>*/;
1567 var3
= ((short int (*)(val
*, val
*))(var2
->class->vft
[COLOR_abstract_collection__Collection__has
]))(var2
, var_key
) /* has on <var2:Collection[Object]>*/;
1573 /* method abstract_collection#MapRead#has_key for (self: Object, Object): Bool */
1574 short int VIRTUAL_abstract_collection__MapRead__has_key(val
* self
, val
* p0
) {
1575 short int var
/* : Bool */;
1576 short int var1
/* : Bool */;
1577 var1
= abstract_collection__MapRead__has_key(self
, p0
);
1582 /* method abstract_collection#MapRead#iterator for (self: MapRead[Object, nullable Object]): MapIterator[Object, nullable Object] */
1583 val
* abstract_collection__MapRead__iterator(val
* self
) {
1584 val
* var
/* : MapIterator[Object, nullable Object] */;
1585 const char* var_class_name
;
1586 var_class_name
= self
== NULL ?
"null" : self
->type
->name
;
1587 fprintf(stderr
, "Runtime error: Abstract method `%s` called on `%s`", "iterator", var_class_name
);
1588 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 293);
1593 /* method abstract_collection#MapRead#iterator for (self: Object): MapIterator[Object, nullable Object] */
1594 val
* VIRTUAL_abstract_collection__MapRead__iterator(val
* self
) {
1595 val
* var
/* : MapIterator[Object, nullable Object] */;
1596 val
* var1
/* : MapIterator[Object, nullable Object] */;
1597 var1
= abstract_collection__MapRead__iterator(self
);
1602 /* method abstract_collection#MapRead#values for (self: MapRead[Object, nullable Object]): Collection[nullable Object] */
1603 val
* abstract_collection__MapRead__values(val
* self
) {
1604 val
* var
/* : Collection[nullable Object] */;
1605 const char* var_class_name
;
1606 var_class_name
= self
== NULL ?
"null" : self
->type
->name
;
1607 fprintf(stderr
, "Runtime error: Abstract method `%s` called on `%s`", "values", var_class_name
);
1608 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 296);
1613 /* method abstract_collection#MapRead#values for (self: Object): Collection[nullable Object] */
1614 val
* VIRTUAL_abstract_collection__MapRead__values(val
* self
) {
1615 val
* var
/* : Collection[nullable Object] */;
1616 val
* var1
/* : Collection[nullable Object] */;
1617 var1
= abstract_collection__MapRead__values(self
);
1622 /* method abstract_collection#MapRead#keys for (self: MapRead[Object, nullable Object]): Collection[Object] */
1623 val
* abstract_collection__MapRead__keys(val
* self
) {
1624 val
* var
/* : Collection[Object] */;
1625 const char* var_class_name
;
1626 var_class_name
= self
== NULL ?
"null" : self
->type
->name
;
1627 fprintf(stderr
, "Runtime error: Abstract method `%s` called on `%s`", "keys", var_class_name
);
1628 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 301);
1633 /* method abstract_collection#MapRead#keys for (self: Object): Collection[Object] */
1634 val
* VIRTUAL_abstract_collection__MapRead__keys(val
* self
) {
1635 val
* var
/* : Collection[Object] */;
1636 val
* var1
/* : Collection[Object] */;
1637 var1
= abstract_collection__MapRead__keys(self
);
1642 /* method abstract_collection#MapRead#is_empty for (self: MapRead[Object, nullable Object]): Bool */
1643 short int abstract_collection__MapRead__is_empty(val
* self
) {
1644 short int var
/* : Bool */;
1645 const char* var_class_name
;
1646 var_class_name
= self
== NULL ?
"null" : self
->type
->name
;
1647 fprintf(stderr
, "Runtime error: Abstract method `%s` called on `%s`", "is_empty", var_class_name
);
1648 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 306);
1653 /* method abstract_collection#MapRead#is_empty for (self: Object): Bool */
1654 short int VIRTUAL_abstract_collection__MapRead__is_empty(val
* self
) {
1655 short int var
/* : Bool */;
1656 short int var1
/* : Bool */;
1657 var1
= abstract_collection__MapRead__is_empty(self
);
1662 /* method abstract_collection#MapRead#length for (self: MapRead[Object, nullable Object]): Int */
1663 long abstract_collection__MapRead__length(val
* self
) {
1664 long var
/* : Int */;
1665 const char* var_class_name
;
1666 var_class_name
= self
== NULL ?
"null" : self
->type
->name
;
1667 fprintf(stderr
, "Runtime error: Abstract method `%s` called on `%s`", "length", var_class_name
);
1668 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 309);
1673 /* method abstract_collection#MapRead#length for (self: Object): Int */
1674 long VIRTUAL_abstract_collection__MapRead__length(val
* self
) {
1675 long var
/* : Int */;
1676 long var1
/* : Int */;
1677 var1
= abstract_collection__MapRead__length(self
);
1682 /* method abstract_collection#Map#[]= for (self: Map[Object, nullable Object], Object, nullable Object) */
1683 void abstract_collection__Map___91d_93d_61d(val
* self
, val
* p0
, val
* p1
) {
1684 short int var
/* : Bool */;
1687 const struct type
* type_struct
;
1688 const char* var_class_name
;
1689 short int var1
/* : Bool */;
1692 const struct type
* type_struct4
;
1693 short int is_nullable
;
1694 const char* var_class_name5
;
1695 const char* var_class_name6
;
1696 /* Covariant cast for argument 0 (key) <p0:Object> isa Map#0 */
1697 /* <p0:Object> isa Map#0 */
1698 type_struct
= self
->type
->resolution_table
->types
[COLOR_abstract_collection__Map_FT0
];
1699 cltype
= type_struct
->color
;
1700 idtype
= type_struct
->id
;
1701 if(cltype
>= p0
->type
->table_size
) {
1704 var
= p0
->type
->type_table
[cltype
] == idtype
;
1707 var_class_name
= p0
== NULL ?
"null" : p0
->type
->name
;
1708 fprintf(stderr
, "Runtime error: Cast failed. Expected `%s`, got `%s`", "Map#0", var_class_name
);
1709 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 339);
1712 /* Covariant cast for argument 1 (item) <p1:nullable Object> isa Map#1 */
1713 /* <p1:nullable Object> isa Map#1 */
1714 type_struct4
= self
->type
->resolution_table
->types
[COLOR_abstract_collection__Map_FT1
];
1715 cltype2
= type_struct4
->color
;
1716 idtype3
= type_struct4
->id
;
1717 is_nullable
= type_struct4
->is_nullable
;
1721 if(cltype2
>= p1
->type
->table_size
) {
1724 var1
= p1
->type
->type_table
[cltype2
] == idtype3
;
1728 var_class_name5
= p1
== NULL ?
"null" : p1
->type
->name
;
1729 fprintf(stderr
, "Runtime error: Cast failed. Expected `%s`, got `%s`", "Map#1", var_class_name5
);
1730 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 339);
1733 var_class_name6
= self
== NULL ?
"null" : self
->type
->name
;
1734 fprintf(stderr
, "Runtime error: Abstract method `%s` called on `%s`", "[]=", var_class_name6
);
1735 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 339);
1739 /* method abstract_collection#Map#[]= for (self: Object, Object, nullable Object) */
1740 void VIRTUAL_abstract_collection__Map___91d_93d_61d(val
* self
, val
* p0
, val
* p1
) {
1741 abstract_collection__Map___91d_93d_61d(self
, p0
, p1
);
1744 /* method abstract_collection#Map#recover_with for (self: Map[Object, nullable Object], Map[Object, nullable Object]) */
1745 void abstract_collection__Map__recover_with(val
* self
, val
* p0
) {
1746 short int var
/* : Bool */;
1749 const struct type
* type_struct
;
1750 const char* var_class_name
;
1751 val
* var_map
/* var map: Map[Object, nullable Object] */;
1752 val
* var1
/* : MapIterator[Object, nullable Object] */;
1753 val
* var_i
/* var i: MapIterator[Object, nullable Object] */;
1754 short int var2
/* : Bool */;
1755 val
* var3
/* : Object */;
1756 val
* var4
/* : nullable Object */;
1757 /* Covariant cast for argument 0 (map) <p0:Map[Object, nullable Object]> isa Map[Map#0, Map#1] */
1758 /* <p0:Map[Object, nullable Object]> isa Map[Map#0, Map#1] */
1759 type_struct
= self
->type
->resolution_table
->types
[COLOR_abstract_collection__Mapabstract_collection__Map_FT0abstract_collection__Map_FT1
];
1760 cltype
= type_struct
->color
;
1761 idtype
= type_struct
->id
;
1762 if(cltype
>= p0
->type
->table_size
) {
1765 var
= p0
->type
->type_table
[cltype
] == idtype
;
1768 var_class_name
= p0
== NULL ?
"null" : p0
->type
->name
;
1769 fprintf(stderr
, "Runtime error: Cast failed. Expected `%s`, got `%s`", "Map[Map#0, Map#1]", var_class_name
);
1770 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 342);
1774 var1
= ((val
* (*)(val
*))(var_map
->class->vft
[COLOR_abstract_collection__MapRead__iterator
]))(var_map
) /* iterator on <var_map:Map[Object, nullable Object]>*/;
1777 var2
= ((short int (*)(val
*))(var_i
->class->vft
[COLOR_abstract_collection__MapIterator__is_ok
]))(var_i
) /* is_ok on <var_i:MapIterator[Object, nullable Object]>*/;
1779 var3
= ((val
* (*)(val
*))(var_i
->class->vft
[COLOR_abstract_collection__MapIterator__key
]))(var_i
) /* key on <var_i:MapIterator[Object, nullable Object]>*/;
1780 var4
= ((val
* (*)(val
*))(var_i
->class->vft
[COLOR_abstract_collection__MapIterator__item
]))(var_i
) /* item on <var_i:MapIterator[Object, nullable Object]>*/;
1781 ((void (*)(val
*, val
*, val
*))(self
->class->vft
[COLOR_abstract_collection__Map___91d_93d_61d
]))(self
, var3
, var4
) /* []= on <self:Map[Object, nullable Object]>*/;
1782 ((void (*)(val
*))(var_i
->class->vft
[COLOR_abstract_collection__MapIterator__next
]))(var_i
) /* next on <var_i:MapIterator[Object, nullable Object]>*/;
1783 CONTINUE_label
: (void)0;
1785 BREAK_label
: (void)0;
1788 /* method abstract_collection#Map#recover_with for (self: Object, Map[Object, nullable Object]) */
1789 void VIRTUAL_abstract_collection__Map__recover_with(val
* self
, val
* p0
) {
1790 abstract_collection__Map__recover_with(self
, p0
);
1793 /* method abstract_collection#Map#clear for (self: Map[Object, nullable Object]) */
1794 void abstract_collection__Map__clear(val
* self
) {
1795 const char* var_class_name
;
1796 var_class_name
= self
== NULL ?
"null" : self
->type
->name
;
1797 fprintf(stderr
, "Runtime error: Abstract method `%s` called on `%s`", "clear", var_class_name
);
1798 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 353);
1802 /* method abstract_collection#Map#clear for (self: Object) */
1803 void VIRTUAL_abstract_collection__Map__clear(val
* self
) {
1804 abstract_collection__Map__clear(self
);
1807 /* method abstract_collection#Map#values for (self: Map[Object, nullable Object]): RemovableCollection[nullable Object] */
1808 val
* abstract_collection__Map__values(val
* self
) {
1809 val
* var
/* : RemovableCollection[nullable Object] */;
1810 const char* var_class_name
;
1811 var_class_name
= self
== NULL ?
"null" : self
->type
->name
;
1812 fprintf(stderr
, "Runtime error: Abstract method `%s` called on `%s`", "values", var_class_name
);
1813 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 356);
1818 /* method abstract_collection#Map#values for (self: Object): Collection[nullable Object] */
1819 val
* VIRTUAL_abstract_collection__Map__values(val
* self
) {
1820 val
* var
/* : Collection[nullable Object] */;
1821 val
* var1
/* : RemovableCollection[nullable Object] */;
1822 var1
= abstract_collection__Map__values(self
);
1827 /* method abstract_collection#Map#keys for (self: Map[Object, nullable Object]): RemovableCollection[Object] */
1828 val
* abstract_collection__Map__keys(val
* self
) {
1829 val
* var
/* : RemovableCollection[Object] */;
1830 const char* var_class_name
;
1831 var_class_name
= self
== NULL ?
"null" : self
->type
->name
;
1832 fprintf(stderr
, "Runtime error: Abstract method `%s` called on `%s`", "keys", var_class_name
);
1833 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 358);
1838 /* method abstract_collection#Map#keys for (self: Object): Collection[Object] */
1839 val
* VIRTUAL_abstract_collection__Map__keys(val
* self
) {
1840 val
* var
/* : Collection[Object] */;
1841 val
* var1
/* : RemovableCollection[Object] */;
1842 var1
= abstract_collection__Map__keys(self
);
1847 /* method abstract_collection#MapIterator#item for (self: MapIterator[Object, nullable Object]): nullable Object */
1848 val
* abstract_collection__MapIterator__item(val
* self
) {
1849 val
* var
/* : nullable Object */;
1850 const char* var_class_name
;
1851 var_class_name
= self
== NULL ?
"null" : self
->type
->name
;
1852 fprintf(stderr
, "Runtime error: Abstract method `%s` called on `%s`", "item", var_class_name
);
1853 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 363);
1858 /* method abstract_collection#MapIterator#item for (self: Object): nullable Object */
1859 val
* VIRTUAL_abstract_collection__MapIterator__item(val
* self
) {
1860 val
* var
/* : nullable Object */;
1861 val
* var1
/* : nullable Object */;
1862 var1
= abstract_collection__MapIterator__item(self
);
1867 /* method abstract_collection#MapIterator#key for (self: MapIterator[Object, nullable Object]): Object */
1868 val
* abstract_collection__MapIterator__key(val
* self
) {
1869 val
* var
/* : Object */;
1870 const char* var_class_name
;
1871 var_class_name
= self
== NULL ?
"null" : self
->type
->name
;
1872 fprintf(stderr
, "Runtime error: Abstract method `%s` called on `%s`", "key", var_class_name
);
1873 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 367);
1878 /* method abstract_collection#MapIterator#key for (self: Object): Object */
1879 val
* VIRTUAL_abstract_collection__MapIterator__key(val
* self
) {
1880 val
* var
/* : Object */;
1881 val
* var1
/* : Object */;
1882 var1
= abstract_collection__MapIterator__key(self
);
1887 /* method abstract_collection#MapIterator#next for (self: MapIterator[Object, nullable Object]) */
1888 void abstract_collection__MapIterator__next(val
* self
) {
1889 const char* var_class_name
;
1890 var_class_name
= self
== NULL ?
"null" : self
->type
->name
;
1891 fprintf(stderr
, "Runtime error: Abstract method `%s` called on `%s`", "next", var_class_name
);
1892 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 371);
1896 /* method abstract_collection#MapIterator#next for (self: Object) */
1897 void VIRTUAL_abstract_collection__MapIterator__next(val
* self
) {
1898 abstract_collection__MapIterator__next(self
);
1901 /* method abstract_collection#MapIterator#is_ok for (self: MapIterator[Object, nullable Object]): Bool */
1902 short int abstract_collection__MapIterator__is_ok(val
* self
) {
1903 short int var
/* : Bool */;
1904 const char* var_class_name
;
1905 var_class_name
= self
== NULL ?
"null" : self
->type
->name
;
1906 fprintf(stderr
, "Runtime error: Abstract method `%s` called on `%s`", "is_ok", var_class_name
);
1907 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 375);
1912 /* method abstract_collection#MapIterator#is_ok for (self: Object): Bool */
1913 short int VIRTUAL_abstract_collection__MapIterator__is_ok(val
* self
) {
1914 short int var
/* : Bool */;
1915 short int var1
/* : Bool */;
1916 var1
= abstract_collection__MapIterator__is_ok(self
);
1921 /* method abstract_collection#MapKeysIterator#iterator for (self: MapKeysIterator[Object, nullable Object]): MapIterator[Object, nullable Object] */
1922 val
* abstract_collection__MapKeysIterator__iterator(val
* self
) {
1923 val
* var
/* : MapIterator[Object, nullable Object] */;
1924 val
* var1
/* : MapIterator[Object, nullable Object] */;
1925 var1
= self
->attrs
[COLOR_abstract_collection__MapKeysIterator___64diterator
].val
; /* @iterator on <self:MapKeysIterator[Object, nullable Object]> */
1927 fprintf(stderr
, "Runtime error: %s", "Uninitialized attribute @iterator");
1928 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 385);
1935 /* method abstract_collection#MapKeysIterator#iterator for (self: Object): MapIterator[Object, nullable Object] */
1936 val
* VIRTUAL_abstract_collection__MapKeysIterator__iterator(val
* self
) {
1937 val
* var
/* : MapIterator[Object, nullable Object] */;
1938 val
* var1
/* : MapIterator[Object, nullable Object] */;
1939 var1
= abstract_collection__MapKeysIterator__iterator(self
);
1944 /* method abstract_collection#MapKeysIterator#iterator= for (self: MapKeysIterator[Object, nullable Object], MapIterator[Object, nullable Object]) */
1945 void abstract_collection__MapKeysIterator__iterator_61d(val
* self
, val
* p0
) {
1946 short int var
/* : Bool */;
1949 const struct type
* type_struct
;
1950 const char* var_class_name
;
1951 /* Covariant cast for argument 0 (iterator) <p0:MapIterator[Object, nullable Object]> isa MapIterator[MapKeysIterator#0, MapKeysIterator#1] */
1952 /* <p0:MapIterator[Object, nullable Object]> isa MapIterator[MapKeysIterator#0, MapKeysIterator#1] */
1953 type_struct
= self
->type
->resolution_table
->types
[COLOR_abstract_collection__MapIteratorabstract_collection__MapKeysIterator_FT0abstract_collection__MapKeysIterator_FT1
];
1954 cltype
= type_struct
->color
;
1955 idtype
= type_struct
->id
;
1956 if(cltype
>= p0
->type
->table_size
) {
1959 var
= p0
->type
->type_table
[cltype
] == idtype
;
1962 var_class_name
= p0
== NULL ?
"null" : p0
->type
->name
;
1963 fprintf(stderr
, "Runtime error: Cast failed. Expected `%s`, got `%s`", "MapIterator[MapKeysIterator#0, MapKeysIterator#1]", var_class_name
);
1964 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 385);
1967 self
->attrs
[COLOR_abstract_collection__MapKeysIterator___64diterator
].val
= p0
; /* @iterator on <self:MapKeysIterator[Object, nullable Object]> */
1970 /* method abstract_collection#MapKeysIterator#iterator= for (self: Object, MapIterator[Object, nullable Object]) */
1971 void VIRTUAL_abstract_collection__MapKeysIterator__iterator_61d(val
* self
, val
* p0
) {
1972 abstract_collection__MapKeysIterator__iterator_61d(self
, p0
);
1975 /* method abstract_collection#MapKeysIterator#is_ok for (self: MapKeysIterator[Object, nullable Object]): Bool */
1976 short int abstract_collection__MapKeysIterator__is_ok(val
* self
) {
1977 short int var
/* : Bool */;
1978 val
* var1
/* : MapIterator[Object, nullable Object] */;
1979 short int var2
/* : Bool */;
1980 var1
= ((val
* (*)(val
*))(self
->class->vft
[COLOR_abstract_collection__MapKeysIterator__iterator
]))(self
) /* iterator on <self:MapKeysIterator[Object, nullable Object]>*/;
1981 var2
= ((short int (*)(val
*))(var1
->class->vft
[COLOR_abstract_collection__MapIterator__is_ok
]))(var1
) /* is_ok on <var1:MapIterator[Object, nullable Object]>*/;
1987 /* method abstract_collection#MapKeysIterator#is_ok for (self: Object): Bool */
1988 short int VIRTUAL_abstract_collection__MapKeysIterator__is_ok(val
* self
) {
1989 short int var
/* : Bool */;
1990 short int var1
/* : Bool */;
1991 var1
= abstract_collection__MapKeysIterator__is_ok(self
);
1996 /* method abstract_collection#MapKeysIterator#next for (self: MapKeysIterator[Object, nullable Object]) */
1997 void abstract_collection__MapKeysIterator__next(val
* self
) {
1998 val
* var
/* : MapIterator[Object, nullable Object] */;
1999 var
= ((val
* (*)(val
*))(self
->class->vft
[COLOR_abstract_collection__MapKeysIterator__iterator
]))(self
) /* iterator on <self:MapKeysIterator[Object, nullable Object]>*/;
2000 ((void (*)(val
*))(var
->class->vft
[COLOR_abstract_collection__MapIterator__next
]))(var
) /* next on <var:MapIterator[Object, nullable Object]>*/;
2003 /* method abstract_collection#MapKeysIterator#next for (self: Object) */
2004 void VIRTUAL_abstract_collection__MapKeysIterator__next(val
* self
) {
2005 abstract_collection__MapKeysIterator__next(self
);
2008 /* method abstract_collection#MapKeysIterator#item for (self: MapKeysIterator[Object, nullable Object]): Object */
2009 val
* abstract_collection__MapKeysIterator__item(val
* self
) {
2010 val
* var
/* : Object */;
2011 val
* var1
/* : MapIterator[Object, nullable Object] */;
2012 val
* var2
/* : Object */;
2013 var1
= ((val
* (*)(val
*))(self
->class->vft
[COLOR_abstract_collection__MapKeysIterator__iterator
]))(self
) /* iterator on <self:MapKeysIterator[Object, nullable Object]>*/;
2014 var2
= ((val
* (*)(val
*))(var1
->class->vft
[COLOR_abstract_collection__MapIterator__key
]))(var1
) /* key on <var1:MapIterator[Object, nullable Object]>*/;
2020 /* method abstract_collection#MapKeysIterator#item for (self: Object): nullable Object */
2021 val
* VIRTUAL_abstract_collection__MapKeysIterator__item(val
* self
) {
2022 val
* var
/* : nullable Object */;
2023 val
* var1
/* : Object */;
2024 var1
= abstract_collection__MapKeysIterator__item(self
);
2029 /* method abstract_collection#MapKeysIterator#init for (self: MapKeysIterator[Object, nullable Object], MapIterator[Object, nullable Object]) */
2030 void abstract_collection__MapKeysIterator__init(val
* self
, val
* p0
) {
2031 short int var
/* : Bool */;
2034 const struct type
* type_struct
;
2035 const char* var_class_name
;
2036 /* Covariant cast for argument 0 (iterator) <p0:MapIterator[Object, nullable Object]> isa MapIterator[MapKeysIterator#0, MapKeysIterator#1] */
2037 /* <p0:MapIterator[Object, nullable Object]> isa MapIterator[MapKeysIterator#0, MapKeysIterator#1] */
2038 type_struct
= self
->type
->resolution_table
->types
[COLOR_abstract_collection__MapIteratorabstract_collection__MapKeysIterator_FT0abstract_collection__MapKeysIterator_FT1
];
2039 cltype
= type_struct
->color
;
2040 idtype
= type_struct
->id
;
2041 if(cltype
>= p0
->type
->table_size
) {
2044 var
= p0
->type
->type_table
[cltype
] == idtype
;
2047 var_class_name
= p0
== NULL ?
"null" : p0
->type
->name
;
2048 fprintf(stderr
, "Runtime error: Cast failed. Expected `%s`, got `%s`", "MapIterator[MapKeysIterator#0, MapKeysIterator#1]", var_class_name
);
2049 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 382);
2052 self
->attrs
[COLOR_abstract_collection__MapKeysIterator___64diterator
].val
= p0
; /* @iterator on <self:MapKeysIterator[Object, nullable Object]> */
2055 /* method abstract_collection#MapKeysIterator#init for (self: Object, MapIterator[Object, nullable Object]) */
2056 void VIRTUAL_abstract_collection__MapKeysIterator__init(val
* self
, val
* p0
) {
2057 abstract_collection__MapKeysIterator__init(self
, p0
);
2060 /* method abstract_collection#MapValuesIterator#iterator for (self: MapValuesIterator[Object, nullable Object]): MapIterator[Object, nullable Object] */
2061 val
* abstract_collection__MapValuesIterator__iterator(val
* self
) {
2062 val
* var
/* : MapIterator[Object, nullable Object] */;
2063 val
* var1
/* : MapIterator[Object, nullable Object] */;
2064 var1
= self
->attrs
[COLOR_abstract_collection__MapValuesIterator___64diterator
].val
; /* @iterator on <self:MapValuesIterator[Object, nullable Object]> */
2066 fprintf(stderr
, "Runtime error: %s", "Uninitialized attribute @iterator");
2067 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 396);
2074 /* method abstract_collection#MapValuesIterator#iterator for (self: Object): MapIterator[Object, nullable Object] */
2075 val
* VIRTUAL_abstract_collection__MapValuesIterator__iterator(val
* self
) {
2076 val
* var
/* : MapIterator[Object, nullable Object] */;
2077 val
* var1
/* : MapIterator[Object, nullable Object] */;
2078 var1
= abstract_collection__MapValuesIterator__iterator(self
);
2083 /* method abstract_collection#MapValuesIterator#iterator= for (self: MapValuesIterator[Object, nullable Object], MapIterator[Object, nullable Object]) */
2084 void abstract_collection__MapValuesIterator__iterator_61d(val
* self
, val
* p0
) {
2085 short int var
/* : Bool */;
2088 const struct type
* type_struct
;
2089 const char* var_class_name
;
2090 /* Covariant cast for argument 0 (iterator) <p0:MapIterator[Object, nullable Object]> isa MapIterator[MapValuesIterator#0, MapValuesIterator#1] */
2091 /* <p0:MapIterator[Object, nullable Object]> isa MapIterator[MapValuesIterator#0, MapValuesIterator#1] */
2092 type_struct
= self
->type
->resolution_table
->types
[COLOR_abstract_collection__MapIteratorabstract_collection__MapValuesIterator_FT0abstract_collection__MapValuesIterator_FT1
];
2093 cltype
= type_struct
->color
;
2094 idtype
= type_struct
->id
;
2095 if(cltype
>= p0
->type
->table_size
) {
2098 var
= p0
->type
->type_table
[cltype
] == idtype
;
2101 var_class_name
= p0
== NULL ?
"null" : p0
->type
->name
;
2102 fprintf(stderr
, "Runtime error: Cast failed. Expected `%s`, got `%s`", "MapIterator[MapValuesIterator#0, MapValuesIterator#1]", var_class_name
);
2103 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 396);
2106 self
->attrs
[COLOR_abstract_collection__MapValuesIterator___64diterator
].val
= p0
; /* @iterator on <self:MapValuesIterator[Object, nullable Object]> */
2109 /* method abstract_collection#MapValuesIterator#iterator= for (self: Object, MapIterator[Object, nullable Object]) */
2110 void VIRTUAL_abstract_collection__MapValuesIterator__iterator_61d(val
* self
, val
* p0
) {
2111 abstract_collection__MapValuesIterator__iterator_61d(self
, p0
);
2114 /* method abstract_collection#MapValuesIterator#is_ok for (self: MapValuesIterator[Object, nullable Object]): Bool */
2115 short int abstract_collection__MapValuesIterator__is_ok(val
* self
) {
2116 short int var
/* : Bool */;
2117 val
* var1
/* : MapIterator[Object, nullable Object] */;
2118 short int var2
/* : Bool */;
2119 var1
= ((val
* (*)(val
*))(self
->class->vft
[COLOR_abstract_collection__MapValuesIterator__iterator
]))(self
) /* iterator on <self:MapValuesIterator[Object, nullable Object]>*/;
2120 var2
= ((short int (*)(val
*))(var1
->class->vft
[COLOR_abstract_collection__MapIterator__is_ok
]))(var1
) /* is_ok on <var1:MapIterator[Object, nullable Object]>*/;
2126 /* method abstract_collection#MapValuesIterator#is_ok for (self: Object): Bool */
2127 short int VIRTUAL_abstract_collection__MapValuesIterator__is_ok(val
* self
) {
2128 short int var
/* : Bool */;
2129 short int var1
/* : Bool */;
2130 var1
= abstract_collection__MapValuesIterator__is_ok(self
);
2135 /* method abstract_collection#MapValuesIterator#next for (self: MapValuesIterator[Object, nullable Object]) */
2136 void abstract_collection__MapValuesIterator__next(val
* self
) {
2137 val
* var
/* : MapIterator[Object, nullable Object] */;
2138 var
= ((val
* (*)(val
*))(self
->class->vft
[COLOR_abstract_collection__MapValuesIterator__iterator
]))(self
) /* iterator on <self:MapValuesIterator[Object, nullable Object]>*/;
2139 ((void (*)(val
*))(var
->class->vft
[COLOR_abstract_collection__MapIterator__next
]))(var
) /* next on <var:MapIterator[Object, nullable Object]>*/;
2142 /* method abstract_collection#MapValuesIterator#next for (self: Object) */
2143 void VIRTUAL_abstract_collection__MapValuesIterator__next(val
* self
) {
2144 abstract_collection__MapValuesIterator__next(self
);
2147 /* method abstract_collection#MapValuesIterator#item for (self: MapValuesIterator[Object, nullable Object]): nullable Object */
2148 val
* abstract_collection__MapValuesIterator__item(val
* self
) {
2149 val
* var
/* : nullable Object */;
2150 val
* var1
/* : MapIterator[Object, nullable Object] */;
2151 val
* var2
/* : nullable Object */;
2152 var1
= ((val
* (*)(val
*))(self
->class->vft
[COLOR_abstract_collection__MapValuesIterator__iterator
]))(self
) /* iterator on <self:MapValuesIterator[Object, nullable Object]>*/;
2153 var2
= ((val
* (*)(val
*))(var1
->class->vft
[COLOR_abstract_collection__MapIterator__item
]))(var1
) /* item on <var1:MapIterator[Object, nullable Object]>*/;
2159 /* method abstract_collection#MapValuesIterator#item for (self: Object): nullable Object */
2160 val
* VIRTUAL_abstract_collection__MapValuesIterator__item(val
* self
) {
2161 val
* var
/* : nullable Object */;
2162 val
* var1
/* : nullable Object */;
2163 var1
= abstract_collection__MapValuesIterator__item(self
);
2168 /* method abstract_collection#MapValuesIterator#init for (self: MapValuesIterator[Object, nullable Object], MapIterator[Object, nullable Object]) */
2169 void abstract_collection__MapValuesIterator__init(val
* self
, val
* p0
) {
2170 short int var
/* : Bool */;
2173 const struct type
* type_struct
;
2174 const char* var_class_name
;
2175 /* Covariant cast for argument 0 (iterator) <p0:MapIterator[Object, nullable Object]> isa MapIterator[MapValuesIterator#0, MapValuesIterator#1] */
2176 /* <p0:MapIterator[Object, nullable Object]> isa MapIterator[MapValuesIterator#0, MapValuesIterator#1] */
2177 type_struct
= self
->type
->resolution_table
->types
[COLOR_abstract_collection__MapIteratorabstract_collection__MapValuesIterator_FT0abstract_collection__MapValuesIterator_FT1
];
2178 cltype
= type_struct
->color
;
2179 idtype
= type_struct
->id
;
2180 if(cltype
>= p0
->type
->table_size
) {
2183 var
= p0
->type
->type_table
[cltype
] == idtype
;
2186 var_class_name
= p0
== NULL ?
"null" : p0
->type
->name
;
2187 fprintf(stderr
, "Runtime error: Cast failed. Expected `%s`, got `%s`", "MapIterator[MapValuesIterator#0, MapValuesIterator#1]", var_class_name
);
2188 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 393);
2191 self
->attrs
[COLOR_abstract_collection__MapValuesIterator___64diterator
].val
= p0
; /* @iterator on <self:MapValuesIterator[Object, nullable Object]> */
2194 /* method abstract_collection#MapValuesIterator#init for (self: Object, MapIterator[Object, nullable Object]) */
2195 void VIRTUAL_abstract_collection__MapValuesIterator__init(val
* self
, val
* p0
) {
2196 abstract_collection__MapValuesIterator__init(self
, p0
);
2199 /* method abstract_collection#SequenceRead#first for (self: SequenceRead[nullable Object]): nullable Object */
2200 val
* abstract_collection__SequenceRead__first(val
* self
) {
2201 val
* var
/* : nullable Object */;
2202 short int var1
/* : Bool */;
2203 short int var2
/* : Bool */;
2204 long var3
/* : Int */;
2205 val
* var4
/* : nullable Object */;
2206 var1
= ((short int (*)(val
*))(self
->class->vft
[COLOR_abstract_collection__Collection__is_empty
]))(self
) /* is_empty on <self:SequenceRead[nullable Object]>*/;
2209 fprintf(stderr
, "Runtime error: %s", "Assert \'not_empty\' failed");
2210 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 412);
2214 var4
= ((val
* (*)(val
*, long))(self
->class->vft
[COLOR_abstract_collection__SequenceRead___91d_93d
]))(self
, var3
) /* [] on <self:SequenceRead[nullable Object]>*/;
2220 /* method abstract_collection#SequenceRead#first for (self: Object): nullable Object */
2221 val
* VIRTUAL_abstract_collection__SequenceRead__first(val
* self
) {
2222 val
* var
/* : nullable Object */;
2223 val
* var1
/* : nullable Object */;
2224 var1
= abstract_collection__SequenceRead__first(self
);
2229 /* method abstract_collection#SequenceRead#[] for (self: SequenceRead[nullable Object], Int): nullable Object */
2230 val
* abstract_collection__SequenceRead___91d_93d(val
* self
, long p0
) {
2231 val
* var
/* : nullable Object */;
2232 const char* var_class_name
;
2233 var_class_name
= self
== NULL ?
"null" : self
->type
->name
;
2234 fprintf(stderr
, "Runtime error: Abstract method `%s` called on `%s`", "[]", var_class_name
);
2235 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 416);
2240 /* method abstract_collection#SequenceRead#[] for (self: Object, Int): nullable Object */
2241 val
* VIRTUAL_abstract_collection__SequenceRead___91d_93d(val
* self
, long p0
) {
2242 val
* var
/* : nullable Object */;
2243 val
* var1
/* : nullable Object */;
2244 var1
= abstract_collection__SequenceRead___91d_93d(self
, p0
);
2249 /* method abstract_collection#SequenceRead#last for (self: SequenceRead[nullable Object]): nullable Object */
2250 val
* abstract_collection__SequenceRead__last(val
* self
) {
2251 val
* var
/* : nullable Object */;
2252 short int var1
/* : Bool */;
2253 short int var2
/* : Bool */;
2254 long var3
/* : Int */;
2255 long var4
/* : Int */;
2256 long var5
/* : Int */;
2257 long var7
/* : Int */;
2258 val
* var8
/* : nullable Object */;
2259 var1
= ((short int (*)(val
*))(self
->class->vft
[COLOR_abstract_collection__Collection__is_empty
]))(self
) /* is_empty on <self:SequenceRead[nullable Object]>*/;
2262 fprintf(stderr
, "Runtime error: %s", "Assert \'not_empty\' failed");
2263 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 425);
2266 var3
= ((long (*)(val
*))(self
->class->vft
[COLOR_abstract_collection__Collection__length
]))(self
) /* length on <self:SequenceRead[nullable Object]>*/;
2268 { /* Inline kernel#Int#- (var3,var4) */
2274 var8
= ((val
* (*)(val
*, long))(self
->class->vft
[COLOR_abstract_collection__SequenceRead___91d_93d
]))(self
, var5
) /* [] on <self:SequenceRead[nullable Object]>*/;
2280 /* method abstract_collection#SequenceRead#last for (self: Object): nullable Object */
2281 val
* VIRTUAL_abstract_collection__SequenceRead__last(val
* self
) {
2282 val
* var
/* : nullable Object */;
2283 val
* var1
/* : nullable Object */;
2284 var1
= abstract_collection__SequenceRead__last(self
);
2289 /* method abstract_collection#SequenceRead#index_of for (self: SequenceRead[nullable Object], nullable Object): Int */
2290 long abstract_collection__SequenceRead__index_of(val
* self
, val
* p0
) {
2291 long var
/* : Int */;
2292 short int var1
/* : Bool */;
2295 const struct type
* type_struct
;
2296 short int is_nullable
;
2297 const char* var_class_name
;
2298 val
* var_item
/* var item: nullable Object */;
2299 val
* var2
/* : Iterator[nullable Object] */;
2300 val
* var_i
/* var i: IndexedIterator[nullable Object] */;
2301 short int var3
/* : Bool */;
2302 val
* var4
/* : nullable Object */;
2303 short int var5
/* : Bool */;
2304 long var6
/* : Int */;
2305 long var7
/* : Int */;
2306 long var8
/* : Int */;
2307 long var10
/* : Int */;
2308 /* Covariant cast for argument 0 (item) <p0:nullable Object> isa SequenceRead#0 */
2309 /* <p0:nullable Object> isa SequenceRead#0 */
2310 type_struct
= self
->type
->resolution_table
->types
[COLOR_abstract_collection__SequenceRead_FT0
];
2311 cltype
= type_struct
->color
;
2312 idtype
= type_struct
->id
;
2313 is_nullable
= type_struct
->is_nullable
;
2317 if(cltype
>= p0
->type
->table_size
) {
2320 var1
= p0
->type
->type_table
[cltype
] == idtype
;
2324 var_class_name
= p0
== NULL ?
"null" : p0
->type
->name
;
2325 fprintf(stderr
, "Runtime error: Cast failed. Expected `%s`, got `%s`", "SequenceRead#0", var_class_name
);
2326 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 429);
2330 var2
= ((val
* (*)(val
*))(self
->class->vft
[COLOR_abstract_collection__Collection__iterator
]))(self
) /* iterator on <self:SequenceRead[nullable Object]>*/;
2333 var3
= ((short int (*)(val
*))(var_i
->class->vft
[COLOR_abstract_collection__Iterator__is_ok
]))(var_i
) /* is_ok on <var_i:IndexedIterator[nullable Object]>*/;
2335 var4
= ((val
* (*)(val
*))(var_i
->class->vft
[COLOR_abstract_collection__Iterator__item
]))(var_i
) /* item on <var_i:IndexedIterator[nullable Object]>*/;
2337 var5
= (var_item
== NULL
);
2339 var5
= ((short int (*)(val
*, val
*))(var4
->class->vft
[COLOR_kernel__Object___61d_61d
]))(var4
, var_item
) /* == on <var4:nullable Object>*/;
2342 var6
= ((long (*)(val
*))(var_i
->class->vft
[COLOR_abstract_collection__IndexedIterator__index
]))(var_i
) /* index on <var_i:IndexedIterator[nullable Object]>*/;
2347 ((void (*)(val
*))(var_i
->class->vft
[COLOR_abstract_collection__Iterator__next
]))(var_i
) /* next on <var_i:IndexedIterator[nullable Object]>*/;
2348 CONTINUE_label
: (void)0;
2350 BREAK_label
: (void)0;
2352 { /* Inline kernel#Int#unary - (var7) */
2363 /* method abstract_collection#SequenceRead#index_of for (self: Object, nullable Object): Int */
2364 long VIRTUAL_abstract_collection__SequenceRead__index_of(val
* self
, val
* p0
) {
2365 long var
/* : Int */;
2366 long var1
/* : Int */;
2367 var1
= abstract_collection__SequenceRead__index_of(self
, p0
);
2372 /* method abstract_collection#SequenceRead#iterator for (self: SequenceRead[nullable Object]): IndexedIterator[nullable Object] */
2373 val
* abstract_collection__SequenceRead__iterator(val
* self
) {
2374 val
* var
/* : IndexedIterator[nullable Object] */;
2375 const char* var_class_name
;
2376 var_class_name
= self
== NULL ?
"null" : self
->type
->name
;
2377 fprintf(stderr
, "Runtime error: Abstract method `%s` called on `%s`", "iterator", var_class_name
);
2378 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 442);
2383 /* method abstract_collection#SequenceRead#iterator for (self: Object): Iterator[nullable Object] */
2384 val
* VIRTUAL_abstract_collection__SequenceRead__iterator(val
* self
) {
2385 val
* var
/* : Iterator[nullable Object] */;
2386 val
* var1
/* : IndexedIterator[nullable Object] */;
2387 var1
= abstract_collection__SequenceRead__iterator(self
);
2392 /* method abstract_collection#SequenceRead#== for (self: SequenceRead[nullable Object], nullable Object): Bool */
2393 short int abstract_collection__SequenceRead___61d_61d(val
* self
, val
* p0
) {
2394 short int var
/* : Bool */;
2395 val
* var_o
/* var o: nullable Object */;
2396 short int var1
/* : Bool */;
2399 short int var2
/* : Bool */;
2400 short int var3
/* : Bool */;
2401 long var4
/* : Int */;
2402 long var_l
/* var l: Int */;
2403 long var5
/* : Int */;
2404 short int var6
/* : Bool */;
2405 short int var8
/* : Bool */;
2406 short int var9
/* : Bool */;
2407 short int var10
/* : Bool */;
2408 long var11
/* : Int */;
2409 long var_i
/* var i: Int */;
2410 short int var12
/* : Bool */;
2411 short int var14
/* : Bool */;
2414 const char* var_class_name
;
2415 short int var17
/* : Bool */;
2416 val
* var18
/* : nullable Object */;
2417 val
* var19
/* : nullable Object */;
2418 short int var20
/* : Bool */;
2419 short int var21
/* : Bool */;
2420 long var22
/* : Int */;
2421 long var23
/* : Int */;
2422 long var25
/* : Int */;
2423 short int var26
/* : Bool */;
2425 /* <var_o:nullable Object> isa SequenceRead[nullable Object] */
2426 cltype
= type_abstract_collection__SequenceReadnullable_kernel__Object
.color
;
2427 idtype
= type_abstract_collection__SequenceReadnullable_kernel__Object
.id
;
2431 if(cltype
>= var_o
->type
->table_size
) {
2434 var1
= var_o
->type
->type_table
[cltype
] == idtype
;
2444 var4
= ((long (*)(val
*))(self
->class->vft
[COLOR_abstract_collection__Collection__length
]))(self
) /* length on <self:SequenceRead[nullable Object]>*/;
2446 var5
= ((long (*)(val
*))(var_o
->class->vft
[COLOR_abstract_collection__Collection__length
]))(var_o
) /* length on <var_o:nullable Object(SequenceRead[nullable Object])>*/;
2447 { /* Inline kernel#Int#!= (var5,var_l) */
2448 var8
= var5
== var_l
;
2463 { /* Inline kernel#Int#< (var_i,var_l) */
2464 /* Covariant cast for argument 0 (i) <var_l:Int> isa OTHER */
2465 /* <var_l:Int> isa OTHER */
2466 var14
= 1; /* easy <var_l:Int> isa OTHER*/
2468 var_class_name
= type_kernel__Int
.name
;
2469 fprintf(stderr
, "Runtime error: Cast failed. Expected `%s`, got `%s`", "OTHER", var_class_name
);
2470 fprintf(stderr
, " (%s:%d)\n", "lib/standard/kernel.nit", 261);
2473 var17
= var_i
< var_l
;
2476 RET_LABEL13
:(void)0;
2479 var18
= ((val
* (*)(val
*, long))(self
->class->vft
[COLOR_abstract_collection__SequenceRead___91d_93d
]))(self
, var_i
) /* [] on <self:SequenceRead[nullable Object]>*/;
2480 var19
= ((val
* (*)(val
*, long))(var_o
->class->vft
[COLOR_abstract_collection__SequenceRead___91d_93d
]))(var_o
, var_i
) /* [] on <var_o:nullable Object(SequenceRead[nullable Object])>*/;
2481 if (var18
== NULL
) {
2482 var20
= (var19
!= NULL
);
2484 var20
= ((short int (*)(val
*, val
*))(var18
->class->vft
[COLOR_kernel__Object___33d_61d
]))(var18
, var19
) /* != on <var18:nullable Object>*/;
2493 { /* Inline kernel#Int#+ (var_i,var22) */
2494 var25
= var_i
+ var22
;
2497 RET_LABEL24
:(void)0;
2500 CONTINUE_label
: (void)0;
2502 BREAK_label
: (void)0;
2509 /* method abstract_collection#SequenceRead#== for (self: Object, nullable Object): Bool */
2510 short int VIRTUAL_abstract_collection__SequenceRead___61d_61d(val
* self
, val
* p0
) {
2511 short int var
/* : Bool */;
2512 short int var1
/* : Bool */;
2513 var1
= abstract_collection__SequenceRead___61d_61d(self
, p0
);
2518 /* method abstract_collection#SequenceRead#hash for (self: SequenceRead[nullable Object]): Int */
2519 long abstract_collection__SequenceRead__hash(val
* self
) {
2520 long var
/* : Int */;
2521 long var1
/* : Int */;
2522 long var_res
/* var res: Int */;
2523 val
* var2
/* : Iterator[nullable Object] */;
2524 short int var3
/* : Bool */;
2525 val
* var4
/* : nullable Object */;
2526 val
* var_e
/* var e: nullable Object */;
2527 long var5
/* : Int */;
2528 long var6
/* : Int */;
2529 long var8
/* : Int */;
2532 var2
= ((val
* (*)(val
*))(self
->class->vft
[COLOR_abstract_collection__Collection__iterator
]))(self
) /* iterator on <self:SequenceRead[nullable Object]>*/;
2534 var3
= ((short int (*)(val
*))(var2
->class->vft
[COLOR_abstract_collection__Iterator__is_ok
]))(var2
) /* is_ok on <var2:Iterator[nullable Object]>*/;
2536 var4
= ((val
* (*)(val
*))(var2
->class->vft
[COLOR_abstract_collection__Iterator__item
]))(var2
) /* item on <var2:Iterator[nullable Object]>*/;
2538 var5
= kernel__Int__hash(var_res
);
2539 { /* Inline kernel#Int#+ (var_res,var5) */
2540 var8
= var_res
+ var5
;
2546 CONTINUE_label
: (void)0;
2547 ((void (*)(val
*))(var2
->class->vft
[COLOR_abstract_collection__Iterator__next
]))(var2
) /* next on <var2:Iterator[nullable Object]>*/;
2549 BREAK_label
: (void)0;
2555 /* method abstract_collection#SequenceRead#hash for (self: Object): Int */
2556 long VIRTUAL_abstract_collection__SequenceRead__hash(val
* self
) {
2557 long var
/* : Int */;
2558 long var1
/* : Int */;
2559 var1
= abstract_collection__SequenceRead__hash(self
);
2564 /* method abstract_collection#Sequence#first= for (self: Sequence[nullable Object], nullable Object) */
2565 void abstract_collection__Sequence__first_61d(val
* self
, val
* p0
) {
2566 short int var
/* : Bool */;
2569 const struct type
* type_struct
;
2570 short int is_nullable
;
2571 const char* var_class_name
;
2572 val
* var_item
/* var item: nullable Object */;
2573 long var1
/* : Int */;
2574 /* Covariant cast for argument 0 (item) <p0:nullable Object> isa Sequence#0 */
2575 /* <p0:nullable Object> isa Sequence#0 */
2576 type_struct
= self
->type
->resolution_table
->types
[COLOR_abstract_collection__Sequence_FT0
];
2577 cltype
= type_struct
->color
;
2578 idtype
= type_struct
->id
;
2579 is_nullable
= type_struct
->is_nullable
;
2583 if(cltype
>= p0
->type
->table_size
) {
2586 var
= p0
->type
->type_table
[cltype
] == idtype
;
2590 var_class_name
= p0
== NULL ?
"null" : p0
->type
->name
;
2591 fprintf(stderr
, "Runtime error: Cast failed. Expected `%s`, got `%s`", "Sequence#0", var_class_name
);
2592 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 473);
2597 ((void (*)(val
*, long, val
*))(self
->class->vft
[COLOR_abstract_collection__Sequence___91d_93d_61d
]))(self
, var1
, var_item
) /* []= on <self:Sequence[nullable Object]>*/;
2600 /* method abstract_collection#Sequence#first= for (self: Object, nullable Object) */
2601 void VIRTUAL_abstract_collection__Sequence__first_61d(val
* self
, val
* p0
) {
2602 abstract_collection__Sequence__first_61d(self
, p0
);
2605 /* method abstract_collection#Sequence#last= for (self: Sequence[nullable Object], nullable Object) */
2606 void abstract_collection__Sequence__last_61d(val
* self
, val
* p0
) {
2607 short int var
/* : Bool */;
2610 const struct type
* type_struct
;
2611 short int is_nullable
;
2612 const char* var_class_name
;
2613 val
* var_item
/* var item: nullable Object */;
2614 long var1
/* : Int */;
2615 long var_l
/* var l: Int */;
2616 long var2
/* : Int */;
2617 short int var3
/* : Bool */;
2618 short int var5
/* : Bool */;
2621 const char* var_class_name8
;
2622 short int var9
/* : Bool */;
2623 long var10
/* : Int */;
2624 long var11
/* : Int */;
2625 long var13
/* : Int */;
2626 long var14
/* : Int */;
2627 /* Covariant cast for argument 0 (item) <p0:nullable Object> isa Sequence#0 */
2628 /* <p0:nullable Object> isa Sequence#0 */
2629 type_struct
= self
->type
->resolution_table
->types
[COLOR_abstract_collection__Sequence_FT0
];
2630 cltype
= type_struct
->color
;
2631 idtype
= type_struct
->id
;
2632 is_nullable
= type_struct
->is_nullable
;
2636 if(cltype
>= p0
->type
->table_size
) {
2639 var
= p0
->type
->type_table
[cltype
] == idtype
;
2643 var_class_name
= p0
== NULL ?
"null" : p0
->type
->name
;
2644 fprintf(stderr
, "Runtime error: Cast failed. Expected `%s`, got `%s`", "Sequence#0", var_class_name
);
2645 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 478);
2649 var1
= ((long (*)(val
*))(self
->class->vft
[COLOR_abstract_collection__Collection__length
]))(self
) /* length on <self:Sequence[nullable Object]>*/;
2652 { /* Inline kernel#Int#> (var_l,var2) */
2653 /* Covariant cast for argument 0 (i) <var2:Int> isa OTHER */
2654 /* <var2:Int> isa OTHER */
2655 var5
= 1; /* easy <var2:Int> isa OTHER*/
2657 var_class_name8
= type_kernel__Int
.name
;
2658 fprintf(stderr
, "Runtime error: Cast failed. Expected `%s`, got `%s`", "OTHER", var_class_name8
);
2659 fprintf(stderr
, " (%s:%d)\n", "lib/standard/kernel.nit", 263);
2662 var9
= var_l
> var2
;
2669 { /* Inline kernel#Int#- (var_l,var10) */
2670 var13
= var_l
- var10
;
2673 RET_LABEL12
:(void)0;
2675 ((void (*)(val
*, long, val
*))(self
->class->vft
[COLOR_abstract_collection__Sequence___91d_93d_61d
]))(self
, var11
, var_item
) /* []= on <self:Sequence[nullable Object]>*/;
2678 ((void (*)(val
*, long, val
*))(self
->class->vft
[COLOR_abstract_collection__Sequence___91d_93d_61d
]))(self
, var14
, var_item
) /* []= on <self:Sequence[nullable Object]>*/;
2682 /* method abstract_collection#Sequence#last= for (self: Object, nullable Object) */
2683 void VIRTUAL_abstract_collection__Sequence__last_61d(val
* self
, val
* p0
) {
2684 abstract_collection__Sequence__last_61d(self
, p0
);
2687 /* method abstract_collection#Sequence#add for (self: Sequence[nullable Object], nullable Object) */
2688 void abstract_collection__Sequence__add(val
* self
, val
* p0
) {
2689 short int var
/* : Bool */;
2692 const struct type
* type_struct
;
2693 short int is_nullable
;
2694 const char* var_class_name
;
2695 val
* var_e
/* var e: nullable Object */;
2696 /* Covariant cast for argument 0 (e) <p0:nullable Object> isa SimpleCollection#0 */
2697 /* <p0:nullable Object> isa SimpleCollection#0 */
2698 type_struct
= self
->type
->resolution_table
->types
[COLOR_abstract_collection__SimpleCollection_FT0
];
2699 cltype
= type_struct
->color
;
2700 idtype
= type_struct
->id
;
2701 is_nullable
= type_struct
->is_nullable
;
2705 if(cltype
>= p0
->type
->table_size
) {
2708 var
= p0
->type
->type_table
[cltype
] == idtype
;
2712 var_class_name
= p0
== NULL ?
"null" : p0
->type
->name
;
2713 fprintf(stderr
, "Runtime error: Cast failed. Expected `%s`, got `%s`", "SimpleCollection#0", var_class_name
);
2714 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 490);
2718 ((void (*)(val
*, val
*))(self
->class->vft
[COLOR_abstract_collection__Sequence__push
]))(self
, var_e
) /* push on <self:Sequence[nullable Object]>*/;
2721 /* method abstract_collection#Sequence#add for (self: Object, nullable Object) */
2722 void VIRTUAL_abstract_collection__Sequence__add(val
* self
, val
* p0
) {
2723 abstract_collection__Sequence__add(self
, p0
);
2726 /* method abstract_collection#Sequence#push for (self: Sequence[nullable Object], nullable Object) */
2727 void abstract_collection__Sequence__push(val
* self
, val
* p0
) {
2728 short int var
/* : Bool */;
2731 const struct type
* type_struct
;
2732 short int is_nullable
;
2733 const char* var_class_name
;
2734 const char* var_class_name1
;
2735 /* Covariant cast for argument 0 (e) <p0:nullable Object> isa Sequence#0 */
2736 /* <p0:nullable Object> isa Sequence#0 */
2737 type_struct
= self
->type
->resolution_table
->types
[COLOR_abstract_collection__Sequence_FT0
];
2738 cltype
= type_struct
->color
;
2739 idtype
= type_struct
->id
;
2740 is_nullable
= type_struct
->is_nullable
;
2744 if(cltype
>= p0
->type
->table_size
) {
2747 var
= p0
->type
->type_table
[cltype
] == idtype
;
2751 var_class_name
= p0
== NULL ?
"null" : p0
->type
->name
;
2752 fprintf(stderr
, "Runtime error: Cast failed. Expected `%s`, got `%s`", "Sequence#0", var_class_name
);
2753 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 493);
2756 var_class_name1
= self
== NULL ?
"null" : self
->type
->name
;
2757 fprintf(stderr
, "Runtime error: Abstract method `%s` called on `%s`", "push", var_class_name1
);
2758 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 493);
2762 /* method abstract_collection#Sequence#push for (self: Object, nullable Object) */
2763 void VIRTUAL_abstract_collection__Sequence__push(val
* self
, val
* p0
) {
2764 abstract_collection__Sequence__push(self
, p0
);
2767 /* method abstract_collection#Sequence#append for (self: Sequence[nullable Object], Collection[nullable Object]) */
2768 void abstract_collection__Sequence__append(val
* self
, val
* p0
) {
2769 short int var
/* : Bool */;
2772 const struct type
* type_struct
;
2773 const char* var_class_name
;
2774 val
* var_coll
/* var coll: Collection[nullable Object] */;
2775 val
* var1
/* : Iterator[nullable Object] */;
2776 short int var2
/* : Bool */;
2777 val
* var3
/* : nullable Object */;
2778 val
* var_i
/* var i: nullable Object */;
2779 /* Covariant cast for argument 0 (coll) <p0:Collection[nullable Object]> isa Collection[Sequence#0] */
2780 /* <p0:Collection[nullable Object]> isa Collection[Sequence#0] */
2781 type_struct
= self
->type
->resolution_table
->types
[COLOR_abstract_collection__Collectionabstract_collection__Sequence_FT0
];
2782 cltype
= type_struct
->color
;
2783 idtype
= type_struct
->id
;
2784 if(cltype
>= p0
->type
->table_size
) {
2787 var
= p0
->type
->type_table
[cltype
] == idtype
;
2790 var_class_name
= p0
== NULL ?
"null" : p0
->type
->name
;
2791 fprintf(stderr
, "Runtime error: Cast failed. Expected `%s`, got `%s`", "Collection[Sequence#0]", var_class_name
);
2792 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 496);
2796 var1
= ((val
* (*)(val
*))(var_coll
->class->vft
[COLOR_abstract_collection__Collection__iterator
]))(var_coll
) /* iterator on <var_coll:Collection[nullable Object]>*/;
2798 var2
= ((short int (*)(val
*))(var1
->class->vft
[COLOR_abstract_collection__Iterator__is_ok
]))(var1
) /* is_ok on <var1:Iterator[nullable Object]>*/;
2800 var3
= ((val
* (*)(val
*))(var1
->class->vft
[COLOR_abstract_collection__Iterator__item
]))(var1
) /* item on <var1:Iterator[nullable Object]>*/;
2802 ((void (*)(val
*, val
*))(self
->class->vft
[COLOR_abstract_collection__Sequence__push
]))(self
, var_i
) /* push on <self:Sequence[nullable Object]>*/;
2803 CONTINUE_label
: (void)0;
2804 ((void (*)(val
*))(var1
->class->vft
[COLOR_abstract_collection__Iterator__next
]))(var1
) /* next on <var1:Iterator[nullable Object]>*/;
2806 BREAK_label
: (void)0;
2809 /* method abstract_collection#Sequence#append for (self: Object, Collection[nullable Object]) */
2810 void VIRTUAL_abstract_collection__Sequence__append(val
* self
, val
* p0
) {
2811 abstract_collection__Sequence__append(self
, p0
);
2814 /* method abstract_collection#Sequence#pop for (self: Sequence[nullable Object]): nullable Object */
2815 val
* abstract_collection__Sequence__pop(val
* self
) {
2816 val
* var
/* : nullable Object */;
2817 const char* var_class_name
;
2818 var_class_name
= self
== NULL ?
"null" : self
->type
->name
;
2819 fprintf(stderr
, "Runtime error: Abstract method `%s` called on `%s`", "pop", var_class_name
);
2820 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 499);
2825 /* method abstract_collection#Sequence#pop for (self: Object): nullable Object */
2826 val
* VIRTUAL_abstract_collection__Sequence__pop(val
* self
) {
2827 val
* var
/* : nullable Object */;
2828 val
* var1
/* : nullable Object */;
2829 var1
= abstract_collection__Sequence__pop(self
);
2834 /* method abstract_collection#Sequence#unshift for (self: Sequence[nullable Object], nullable Object) */
2835 void abstract_collection__Sequence__unshift(val
* self
, val
* p0
) {
2836 short int var
/* : Bool */;
2839 const struct type
* type_struct
;
2840 short int is_nullable
;
2841 const char* var_class_name
;
2842 const char* var_class_name1
;
2843 /* Covariant cast for argument 0 (e) <p0:nullable Object> isa Sequence#0 */
2844 /* <p0:nullable Object> isa Sequence#0 */
2845 type_struct
= self
->type
->resolution_table
->types
[COLOR_abstract_collection__Sequence_FT0
];
2846 cltype
= type_struct
->color
;
2847 idtype
= type_struct
->id
;
2848 is_nullable
= type_struct
->is_nullable
;
2852 if(cltype
>= p0
->type
->table_size
) {
2855 var
= p0
->type
->type_table
[cltype
] == idtype
;
2859 var_class_name
= p0
== NULL ?
"null" : p0
->type
->name
;
2860 fprintf(stderr
, "Runtime error: Cast failed. Expected `%s`, got `%s`", "Sequence#0", var_class_name
);
2861 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 502);
2864 var_class_name1
= self
== NULL ?
"null" : self
->type
->name
;
2865 fprintf(stderr
, "Runtime error: Abstract method `%s` called on `%s`", "unshift", var_class_name1
);
2866 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 502);
2870 /* method abstract_collection#Sequence#unshift for (self: Object, nullable Object) */
2871 void VIRTUAL_abstract_collection__Sequence__unshift(val
* self
, val
* p0
) {
2872 abstract_collection__Sequence__unshift(self
, p0
);
2875 /* method abstract_collection#Sequence#shift for (self: Sequence[nullable Object]): nullable Object */
2876 val
* abstract_collection__Sequence__shift(val
* self
) {
2877 val
* var
/* : nullable Object */;
2878 const char* var_class_name
;
2879 var_class_name
= self
== NULL ?
"null" : self
->type
->name
;
2880 fprintf(stderr
, "Runtime error: Abstract method `%s` called on `%s`", "shift", var_class_name
);
2881 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 505);
2886 /* method abstract_collection#Sequence#shift for (self: Object): nullable Object */
2887 val
* VIRTUAL_abstract_collection__Sequence__shift(val
* self
) {
2888 val
* var
/* : nullable Object */;
2889 val
* var1
/* : nullable Object */;
2890 var1
= abstract_collection__Sequence__shift(self
);
2895 /* method abstract_collection#Sequence#[]= for (self: Sequence[nullable Object], Int, nullable Object) */
2896 void abstract_collection__Sequence___91d_93d_61d(val
* self
, long p0
, val
* p1
) {
2897 short int var
/* : Bool */;
2900 const struct type
* type_struct
;
2901 short int is_nullable
;
2902 const char* var_class_name
;
2903 const char* var_class_name1
;
2904 /* Covariant cast for argument 1 (item) <p1:nullable Object> isa Sequence#0 */
2905 /* <p1:nullable Object> isa Sequence#0 */
2906 type_struct
= self
->type
->resolution_table
->types
[COLOR_abstract_collection__Sequence_FT0
];
2907 cltype
= type_struct
->color
;
2908 idtype
= type_struct
->id
;
2909 is_nullable
= type_struct
->is_nullable
;
2913 if(cltype
>= p1
->type
->table_size
) {
2916 var
= p1
->type
->type_table
[cltype
] == idtype
;
2920 var_class_name
= p1
== NULL ?
"null" : p1
->type
->name
;
2921 fprintf(stderr
, "Runtime error: Cast failed. Expected `%s`, got `%s`", "Sequence#0", var_class_name
);
2922 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 509);
2925 var_class_name1
= self
== NULL ?
"null" : self
->type
->name
;
2926 fprintf(stderr
, "Runtime error: Abstract method `%s` called on `%s`", "[]=", var_class_name1
);
2927 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 509);
2931 /* method abstract_collection#Sequence#[]= for (self: Object, Int, nullable Object) */
2932 void VIRTUAL_abstract_collection__Sequence___91d_93d_61d(val
* self
, long p0
, val
* p1
) {
2933 abstract_collection__Sequence___91d_93d_61d(self
, p0
, p1
);
2936 /* method abstract_collection#Sequence#remove_at for (self: Sequence[nullable Object], Int) */
2937 void abstract_collection__Sequence__remove_at(val
* self
, long p0
) {
2938 const char* var_class_name
;
2939 var_class_name
= self
== NULL ?
"null" : self
->type
->name
;
2940 fprintf(stderr
, "Runtime error: Abstract method `%s` called on `%s`", "remove_at", var_class_name
);
2941 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 512);
2945 /* method abstract_collection#Sequence#remove_at for (self: Object, Int) */
2946 void VIRTUAL_abstract_collection__Sequence__remove_at(val
* self
, long p0
) {
2947 abstract_collection__Sequence__remove_at(self
, p0
);
2950 /* method abstract_collection#IndexedIterator#index for (self: IndexedIterator[nullable Object]): Int */
2951 long abstract_collection__IndexedIterator__index(val
* self
) {
2952 long var
/* : Int */;
2953 const char* var_class_name
;
2954 var_class_name
= self
== NULL ?
"null" : self
->type
->name
;
2955 fprintf(stderr
, "Runtime error: Abstract method `%s` called on `%s`", "index", var_class_name
);
2956 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 519);
2961 /* method abstract_collection#IndexedIterator#index for (self: Object): Int */
2962 long VIRTUAL_abstract_collection__IndexedIterator__index(val
* self
) {
2963 long var
/* : Int */;
2964 long var1
/* : Int */;
2965 var1
= abstract_collection__IndexedIterator__index(self
);
2970 /* method abstract_collection#CoupleMap#couple_at for (self: CoupleMap[Object, nullable Object], Object): nullable Couple[Object, nullable Object] */
2971 val
* abstract_collection__CoupleMap__couple_at(val
* self
, val
* p0
) {
2972 val
* var
/* : nullable Couple[Object, nullable Object] */;
2973 short int var1
/* : Bool */;
2976 const struct type
* type_struct
;
2977 const char* var_class_name
;
2978 const char* var_class_name2
;
2979 /* Covariant cast for argument 0 (key) <p0:Object> isa CoupleMap#0 */
2980 /* <p0:Object> isa CoupleMap#0 */
2981 type_struct
= self
->type
->resolution_table
->types
[COLOR_abstract_collection__CoupleMap_FT0
];
2982 cltype
= type_struct
->color
;
2983 idtype
= type_struct
->id
;
2984 if(cltype
>= p0
->type
->table_size
) {
2987 var1
= p0
->type
->type_table
[cltype
] == idtype
;
2990 var_class_name
= p0
== NULL ?
"null" : p0
->type
->name
;
2991 fprintf(stderr
, "Runtime error: Cast failed. Expected `%s`, got `%s`", "CoupleMap#0", var_class_name
);
2992 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 526);
2995 var_class_name2
= self
== NULL ?
"null" : self
->type
->name
;
2996 fprintf(stderr
, "Runtime error: Abstract method `%s` called on `%s`", "couple_at", var_class_name2
);
2997 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 526);
3002 /* method abstract_collection#CoupleMap#couple_at for (self: Object, Object): nullable Couple[Object, nullable Object] */
3003 val
* VIRTUAL_abstract_collection__CoupleMap__couple_at(val
* self
, val
* p0
) {
3004 val
* var
/* : nullable Couple[Object, nullable Object] */;
3005 val
* var1
/* : nullable Couple[Object, nullable Object] */;
3006 var1
= abstract_collection__CoupleMap__couple_at(self
, p0
);
3011 /* method abstract_collection#CoupleMap#[] for (self: CoupleMap[Object, nullable Object], Object): nullable Object */
3012 val
* abstract_collection__CoupleMap___91d_93d(val
* self
, val
* p0
) {
3013 val
* var
/* : nullable Object */;
3014 short int var1
/* : Bool */;
3017 const struct type
* type_struct
;
3018 const char* var_class_name
;
3019 val
* var_key
/* var key: Object */;
3020 val
* var2
/* : nullable Couple[Object, nullable Object] */;
3021 val
* var_c
/* var c: nullable Couple[Object, nullable Object] */;
3022 val
* var3
/* : null */;
3023 short int var4
/* : Bool */;
3024 val
* var5
/* : nullable Object */;
3025 /* Covariant cast for argument 0 (key) <p0:Object> isa MapRead#0 */
3026 /* <p0:Object> isa MapRead#0 */
3027 type_struct
= self
->type
->resolution_table
->types
[COLOR_abstract_collection__MapRead_FT0
];
3028 cltype
= type_struct
->color
;
3029 idtype
= type_struct
->id
;
3030 if(cltype
>= p0
->type
->table_size
) {
3033 var1
= p0
->type
->type_table
[cltype
] == idtype
;
3036 var_class_name
= p0
== NULL ?
"null" : p0
->type
->name
;
3037 fprintf(stderr
, "Runtime error: Cast failed. Expected `%s`, got `%s`", "MapRead#0", var_class_name
);
3038 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 530);
3042 var2
= ((val
* (*)(val
*, val
*))(self
->class->vft
[COLOR_abstract_collection__CoupleMap__couple_at
]))(self
, var_key
) /* couple_at on <self:CoupleMap[Object, nullable Object]>*/;
3045 if (var_c
== NULL
) {
3046 var4
= 1; /* is null */
3048 var4
= 0; /* arg is null but recv is not */
3051 fprintf(stderr
, "Runtime error: %s", "Aborted");
3052 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 534);
3055 var5
= ((val
* (*)(val
*))(var_c
->class->vft
[COLOR_abstract_collection__Couple__second
]))(var_c
) /* second on <var_c:nullable Couple[Object, nullable Object](Couple[Object, nullable Object])>*/;
3062 /* method abstract_collection#CoupleMap#[] for (self: Object, Object): nullable Object */
3063 val
* VIRTUAL_abstract_collection__CoupleMap___91d_93d(val
* self
, val
* p0
) {
3064 val
* var
/* : nullable Object */;
3065 val
* var1
/* : nullable Object */;
3066 var1
= abstract_collection__CoupleMap___91d_93d(self
, p0
);
3071 /* method abstract_collection#CoupleMapIterator#item for (self: CoupleMapIterator[Object, nullable Object]): nullable Object */
3072 val
* abstract_collection__CoupleMapIterator__item(val
* self
) {
3073 val
* var
/* : nullable Object */;
3074 val
* var1
/* : Iterator[Couple[Object, nullable Object]] */;
3075 val
* var2
/* : nullable Object */;
3076 val
* var3
/* : nullable Object */;
3077 var1
= self
->attrs
[COLOR_abstract_collection__CoupleMapIterator___iter
].val
; /* _iter on <self:CoupleMapIterator[Object, nullable Object]> */
3079 fprintf(stderr
, "Runtime error: %s", "Uninitialized attribute _iter");
3080 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 546);
3083 var2
= ((val
* (*)(val
*))(var1
->class->vft
[COLOR_abstract_collection__Iterator__item
]))(var1
) /* item on <var1:Iterator[Couple[Object, nullable Object]]>*/;
3084 var3
= ((val
* (*)(val
*))(var2
->class->vft
[COLOR_abstract_collection__Couple__second
]))(var2
) /* second on <var2:nullable Object(Couple[Object, nullable Object])>*/;
3090 /* method abstract_collection#CoupleMapIterator#item for (self: Object): nullable Object */
3091 val
* VIRTUAL_abstract_collection__CoupleMapIterator__item(val
* self
) {
3092 val
* var
/* : nullable Object */;
3093 val
* var1
/* : nullable Object */;
3094 var1
= abstract_collection__CoupleMapIterator__item(self
);
3099 /* method abstract_collection#CoupleMapIterator#key for (self: CoupleMapIterator[Object, nullable Object]): Object */
3100 val
* abstract_collection__CoupleMapIterator__key(val
* self
) {
3101 val
* var
/* : Object */;
3102 val
* var1
/* : Iterator[Couple[Object, nullable Object]] */;
3103 val
* var2
/* : nullable Object */;
3104 val
* var3
/* : nullable Object */;
3105 var1
= self
->attrs
[COLOR_abstract_collection__CoupleMapIterator___iter
].val
; /* _iter on <self:CoupleMapIterator[Object, nullable Object]> */
3107 fprintf(stderr
, "Runtime error: %s", "Uninitialized attribute _iter");
3108 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 550);
3111 var2
= ((val
* (*)(val
*))(var1
->class->vft
[COLOR_abstract_collection__Iterator__item
]))(var1
) /* item on <var1:Iterator[Couple[Object, nullable Object]]>*/;
3112 var3
= ((val
* (*)(val
*))(var2
->class->vft
[COLOR_abstract_collection__Couple__first
]))(var2
) /* first on <var2:nullable Object(Couple[Object, nullable Object])>*/;
3118 /* method abstract_collection#CoupleMapIterator#key for (self: Object): Object */
3119 val
* VIRTUAL_abstract_collection__CoupleMapIterator__key(val
* self
) {
3120 val
* var
/* : Object */;
3121 val
* var1
/* : Object */;
3122 var1
= abstract_collection__CoupleMapIterator__key(self
);
3127 /* method abstract_collection#CoupleMapIterator#is_ok for (self: CoupleMapIterator[Object, nullable Object]): Bool */
3128 short int abstract_collection__CoupleMapIterator__is_ok(val
* self
) {
3129 short int var
/* : Bool */;
3130 val
* var1
/* : Iterator[Couple[Object, nullable Object]] */;
3131 short int var2
/* : Bool */;
3132 var1
= self
->attrs
[COLOR_abstract_collection__CoupleMapIterator___iter
].val
; /* _iter on <self:CoupleMapIterator[Object, nullable Object]> */
3134 fprintf(stderr
, "Runtime error: %s", "Uninitialized attribute _iter");
3135 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 552);
3138 var2
= ((short int (*)(val
*))(var1
->class->vft
[COLOR_abstract_collection__Iterator__is_ok
]))(var1
) /* is_ok on <var1:Iterator[Couple[Object, nullable Object]]>*/;
3144 /* method abstract_collection#CoupleMapIterator#is_ok for (self: Object): Bool */
3145 short int VIRTUAL_abstract_collection__CoupleMapIterator__is_ok(val
* self
) {
3146 short int var
/* : Bool */;
3147 short int var1
/* : Bool */;
3148 var1
= abstract_collection__CoupleMapIterator__is_ok(self
);
3153 /* method abstract_collection#CoupleMapIterator#next for (self: CoupleMapIterator[Object, nullable Object]) */
3154 void abstract_collection__CoupleMapIterator__next(val
* self
) {
3155 val
* var
/* : Iterator[Couple[Object, nullable Object]] */;
3156 var
= self
->attrs
[COLOR_abstract_collection__CoupleMapIterator___iter
].val
; /* _iter on <self:CoupleMapIterator[Object, nullable Object]> */
3158 fprintf(stderr
, "Runtime error: %s", "Uninitialized attribute _iter");
3159 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 556);
3162 ((void (*)(val
*))(var
->class->vft
[COLOR_abstract_collection__Iterator__next
]))(var
) /* next on <var:Iterator[Couple[Object, nullable Object]]>*/;
3165 /* method abstract_collection#CoupleMapIterator#next for (self: Object) */
3166 void VIRTUAL_abstract_collection__CoupleMapIterator__next(val
* self
) {
3167 abstract_collection__CoupleMapIterator__next(self
);
3170 /* method abstract_collection#CoupleMapIterator#init for (self: CoupleMapIterator[Object, nullable Object], Iterator[Couple[Object, nullable Object]]) */
3171 void abstract_collection__CoupleMapIterator__init(val
* self
, val
* p0
) {
3172 short int var
/* : Bool */;
3175 const struct type
* type_struct
;
3176 const char* var_class_name
;
3177 val
* var_i
/* var i: Iterator[Couple[Object, nullable Object]] */;
3178 /* Covariant cast for argument 0 (i) <p0:Iterator[Couple[Object, nullable Object]]> isa Iterator[Couple[CoupleMapIterator#0, CoupleMapIterator#1]] */
3179 /* <p0:Iterator[Couple[Object, nullable Object]]> isa Iterator[Couple[CoupleMapIterator#0, CoupleMapIterator#1]] */
3180 type_struct
= self
->type
->resolution_table
->types
[COLOR_abstract_collection__Iteratorabstract_collection__Coupleabstract_collection__CoupleMapIterator_FT0abstract_collection__CoupleMapIterator_FT1
];
3181 cltype
= type_struct
->color
;
3182 idtype
= type_struct
->id
;
3183 if(cltype
>= p0
->type
->table_size
) {
3186 var
= p0
->type
->type_table
[cltype
] == idtype
;
3189 var_class_name
= p0
== NULL ?
"null" : p0
->type
->name
;
3190 fprintf(stderr
, "Runtime error: Cast failed. Expected `%s`, got `%s`", "Iterator[Couple[CoupleMapIterator#0, CoupleMapIterator#1]]", var_class_name
);
3191 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 561);
3195 self
->attrs
[COLOR_abstract_collection__CoupleMapIterator___iter
].val
= var_i
; /* _iter on <self:CoupleMapIterator[Object, nullable Object]> */
3198 /* method abstract_collection#CoupleMapIterator#init for (self: Object, Iterator[Couple[Object, nullable Object]]) */
3199 void VIRTUAL_abstract_collection__CoupleMapIterator__init(val
* self
, val
* p0
) {
3200 abstract_collection__CoupleMapIterator__init(self
, p0
);
3203 /* method abstract_collection#Couple#first for (self: Couple[nullable Object, nullable Object]): nullable Object */
3204 val
* abstract_collection__Couple__first(val
* self
) {
3205 val
* var
/* : nullable Object */;
3206 val
* var1
/* : nullable Object */;
3207 var1
= self
->attrs
[COLOR_abstract_collection__Couple___first
].val
; /* _first on <self:Couple[nullable Object, nullable Object]> */
3212 /* method abstract_collection#Couple#first for (self: Object): nullable Object */
3213 val
* VIRTUAL_abstract_collection__Couple__first(val
* self
) {
3214 val
* var
/* : nullable Object */;
3215 val
* var1
/* : nullable Object */;
3216 var1
= abstract_collection__Couple__first(self
);
3221 /* method abstract_collection#Couple#first= for (self: Couple[nullable Object, nullable Object], nullable Object) */
3222 void abstract_collection__Couple__first_61d(val
* self
, val
* p0
) {
3223 short int var
/* : Bool */;
3226 const struct type
* type_struct
;
3227 short int is_nullable
;
3228 const char* var_class_name
;
3229 /* Covariant cast for argument 0 (first) <p0:nullable Object> isa Couple#0 */
3230 /* <p0:nullable Object> isa Couple#0 */
3231 type_struct
= self
->type
->resolution_table
->types
[COLOR_abstract_collection__Couple_FT0
];
3232 cltype
= type_struct
->color
;
3233 idtype
= type_struct
->id
;
3234 is_nullable
= type_struct
->is_nullable
;
3238 if(cltype
>= p0
->type
->table_size
) {
3241 var
= p0
->type
->type_table
[cltype
] == idtype
;
3245 var_class_name
= p0
== NULL ?
"null" : p0
->type
->name
;
3246 fprintf(stderr
, "Runtime error: Cast failed. Expected `%s`, got `%s`", "Couple#0", var_class_name
);
3247 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 569);
3250 self
->attrs
[COLOR_abstract_collection__Couple___first
].val
= p0
; /* _first on <self:Couple[nullable Object, nullable Object]> */
3253 /* method abstract_collection#Couple#first= for (self: Object, nullable Object) */
3254 void VIRTUAL_abstract_collection__Couple__first_61d(val
* self
, val
* p0
) {
3255 abstract_collection__Couple__first_61d(self
, p0
);
3258 /* method abstract_collection#Couple#second for (self: Couple[nullable Object, nullable Object]): nullable Object */
3259 val
* abstract_collection__Couple__second(val
* self
) {
3260 val
* var
/* : nullable Object */;
3261 val
* var1
/* : nullable Object */;
3262 var1
= self
->attrs
[COLOR_abstract_collection__Couple___second
].val
; /* _second on <self:Couple[nullable Object, nullable Object]> */
3267 /* method abstract_collection#Couple#second for (self: Object): nullable Object */
3268 val
* VIRTUAL_abstract_collection__Couple__second(val
* self
) {
3269 val
* var
/* : nullable Object */;
3270 val
* var1
/* : nullable Object */;
3271 var1
= abstract_collection__Couple__second(self
);
3276 /* method abstract_collection#Couple#second= for (self: Couple[nullable Object, nullable Object], nullable Object) */
3277 void abstract_collection__Couple__second_61d(val
* self
, val
* p0
) {
3278 short int var
/* : Bool */;
3281 const struct type
* type_struct
;
3282 short int is_nullable
;
3283 const char* var_class_name
;
3284 /* Covariant cast for argument 0 (second) <p0:nullable Object> isa Couple#1 */
3285 /* <p0:nullable Object> isa Couple#1 */
3286 type_struct
= self
->type
->resolution_table
->types
[COLOR_abstract_collection__Couple_FT1
];
3287 cltype
= type_struct
->color
;
3288 idtype
= type_struct
->id
;
3289 is_nullable
= type_struct
->is_nullable
;
3293 if(cltype
>= p0
->type
->table_size
) {
3296 var
= p0
->type
->type_table
[cltype
] == idtype
;
3300 var_class_name
= p0
== NULL ?
"null" : p0
->type
->name
;
3301 fprintf(stderr
, "Runtime error: Cast failed. Expected `%s`, got `%s`", "Couple#1", var_class_name
);
3302 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 572);
3305 self
->attrs
[COLOR_abstract_collection__Couple___second
].val
= p0
; /* _second on <self:Couple[nullable Object, nullable Object]> */
3308 /* method abstract_collection#Couple#second= for (self: Object, nullable Object) */
3309 void VIRTUAL_abstract_collection__Couple__second_61d(val
* self
, val
* p0
) {
3310 abstract_collection__Couple__second_61d(self
, p0
);
3313 /* method abstract_collection#Couple#init for (self: Couple[nullable Object, nullable Object], nullable Object, nullable Object) */
3314 void abstract_collection__Couple__init(val
* self
, val
* p0
, val
* p1
) {
3315 short int var
/* : Bool */;
3318 const struct type
* type_struct
;
3319 short int is_nullable
;
3320 const char* var_class_name
;
3321 short int var1
/* : Bool */;
3324 const struct type
* type_struct4
;
3325 short int is_nullable5
;
3326 const char* var_class_name6
;
3327 val
* var_f
/* var f: nullable Object */;
3328 val
* var_s
/* var s: nullable Object */;
3329 /* Covariant cast for argument 0 (f) <p0:nullable Object> isa Couple#0 */
3330 /* <p0:nullable Object> isa Couple#0 */
3331 type_struct
= self
->type
->resolution_table
->types
[COLOR_abstract_collection__Couple_FT0
];
3332 cltype
= type_struct
->color
;
3333 idtype
= type_struct
->id
;
3334 is_nullable
= type_struct
->is_nullable
;
3338 if(cltype
>= p0
->type
->table_size
) {
3341 var
= p0
->type
->type_table
[cltype
] == idtype
;
3345 var_class_name
= p0
== NULL ?
"null" : p0
->type
->name
;
3346 fprintf(stderr
, "Runtime error: Cast failed. Expected `%s`, got `%s`", "Couple#0", var_class_name
);
3347 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 575);
3350 /* Covariant cast for argument 1 (s) <p1:nullable Object> isa Couple#1 */
3351 /* <p1:nullable Object> isa Couple#1 */
3352 type_struct4
= self
->type
->resolution_table
->types
[COLOR_abstract_collection__Couple_FT1
];
3353 cltype2
= type_struct4
->color
;
3354 idtype3
= type_struct4
->id
;
3355 is_nullable5
= type_struct4
->is_nullable
;
3357 var1
= is_nullable5
;
3359 if(cltype2
>= p1
->type
->table_size
) {
3362 var1
= p1
->type
->type_table
[cltype2
] == idtype3
;
3366 var_class_name6
= p1
== NULL ?
"null" : p1
->type
->name
;
3367 fprintf(stderr
, "Runtime error: Cast failed. Expected `%s`, got `%s`", "Couple#1", var_class_name6
);
3368 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 575);
3373 self
->attrs
[COLOR_abstract_collection__Couple___first
].val
= var_f
; /* _first on <self:Couple[nullable Object, nullable Object]> */
3374 self
->attrs
[COLOR_abstract_collection__Couple___second
].val
= var_s
; /* _second on <self:Couple[nullable Object, nullable Object]> */
3377 /* method abstract_collection#Couple#init for (self: Object, nullable Object, nullable Object) */
3378 void VIRTUAL_abstract_collection__Couple__init(val
* self
, val
* p0
, val
* p1
) {
3379 abstract_collection__Couple__init(self
, p0
, p1
);