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", 163);
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", 165);
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", 167);
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]>*/;
737 CHECK_NEW_abstract_collection__ContainerIterator(var1
);
743 /* method abstract_collection#Container#iterator for (self: Object): Iterator[nullable Object] */
744 val
* VIRTUAL_abstract_collection__Container__iterator(val
* self
) {
745 val
* var
/* : Iterator[nullable Object] */;
746 val
* var1
/* : Iterator[nullable Object] */;
747 var1
= abstract_collection__Container__iterator(self
);
752 /* method abstract_collection#Container#init for (self: Container[nullable Object], nullable Object) */
753 void abstract_collection__Container__init(val
* self
, val
* p0
) {
754 short int var
/* : Bool */;
757 const struct type
* type_struct
;
758 short int is_nullable
;
759 const char* var_class_name
;
760 val
* var_e
/* var e: nullable Object */;
761 /* Covariant cast for argument 0 (e) <p0:nullable Object> isa Container#0 */
762 /* <p0:nullable Object> isa Container#0 */
763 type_struct
= self
->type
->resolution_table
->types
[COLOR_abstract_collection__Container_FT0
];
764 cltype
= type_struct
->color
;
765 idtype
= type_struct
->id
;
766 is_nullable
= type_struct
->is_nullable
;
770 if(cltype
>= p0
->type
->table_size
) {
773 var
= p0
->type
->type_table
[cltype
] == idtype
;
777 var_class_name
= p0
== NULL ?
"null" : p0
->type
->name
;
778 fprintf(stderr
, "Runtime error: Cast failed. Expected `%s`, got `%s`", "Container#0", var_class_name
);
779 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 178);
783 self
->attrs
[COLOR_abstract_collection__Container___item
].val
= var_e
; /* _item on <self:Container[nullable Object]> */
786 /* method abstract_collection#Container#init for (self: Object, nullable Object) */
787 void VIRTUAL_abstract_collection__Container__init(val
* self
, val
* p0
) {
788 abstract_collection__Container__init(self
, p0
);
791 /* method abstract_collection#Container#item for (self: Container[nullable Object]): nullable Object */
792 val
* abstract_collection__Container__item(val
* self
) {
793 val
* var
/* : nullable Object */;
794 val
* var1
/* : nullable Object */;
795 var1
= self
->attrs
[COLOR_abstract_collection__Container___item
].val
; /* _item on <self:Container[nullable Object]> */
800 /* method abstract_collection#Container#item for (self: Object): nullable Object */
801 val
* VIRTUAL_abstract_collection__Container__item(val
* self
) {
802 val
* var
/* : nullable Object */;
803 val
* var1
/* : nullable Object */;
804 var1
= abstract_collection__Container__item(self
);
809 /* method abstract_collection#Container#item= for (self: Container[nullable Object], nullable Object) */
810 void abstract_collection__Container__item_61d(val
* self
, val
* p0
) {
811 short int var
/* : Bool */;
814 const struct type
* type_struct
;
815 short int is_nullable
;
816 const char* var_class_name
;
817 /* Covariant cast for argument 0 (item) <p0:nullable Object> isa Container#0 */
818 /* <p0:nullable Object> isa Container#0 */
819 type_struct
= self
->type
->resolution_table
->types
[COLOR_abstract_collection__Container_FT0
];
820 cltype
= type_struct
->color
;
821 idtype
= type_struct
->id
;
822 is_nullable
= type_struct
->is_nullable
;
826 if(cltype
>= p0
->type
->table_size
) {
829 var
= p0
->type
->type_table
[cltype
] == idtype
;
833 var_class_name
= p0
== NULL ?
"null" : p0
->type
->name
;
834 fprintf(stderr
, "Runtime error: Cast failed. Expected `%s`, got `%s`", "Container#0", var_class_name
);
835 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 181);
838 self
->attrs
[COLOR_abstract_collection__Container___item
].val
= p0
; /* _item on <self:Container[nullable Object]> */
841 /* method abstract_collection#Container#item= for (self: Object, nullable Object) */
842 void VIRTUAL_abstract_collection__Container__item_61d(val
* self
, val
* p0
) {
843 abstract_collection__Container__item_61d(self
, p0
);
846 /* method abstract_collection#ContainerIterator#item for (self: ContainerIterator[nullable Object]): nullable Object */
847 val
* abstract_collection__ContainerIterator__item(val
* self
) {
848 val
* var
/* : nullable Object */;
849 val
* var1
/* : Container[nullable Object] */;
850 val
* var2
/* : nullable Object */;
851 var1
= self
->attrs
[COLOR_abstract_collection__ContainerIterator___container
].val
; /* _container on <self:ContainerIterator[nullable Object]> */
853 fprintf(stderr
, "Runtime error: %s", "Uninitialized attribute _container");
854 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 188);
857 var2
= ((val
* (*)(val
*))(var1
->class->vft
[COLOR_abstract_collection__Container__item
]))(var1
) /* item on <var1:Container[nullable Object]>*/;
863 /* method abstract_collection#ContainerIterator#item for (self: Object): nullable Object */
864 val
* VIRTUAL_abstract_collection__ContainerIterator__item(val
* self
) {
865 val
* var
/* : nullable Object */;
866 val
* var1
/* : nullable Object */;
867 var1
= abstract_collection__ContainerIterator__item(self
);
872 /* method abstract_collection#ContainerIterator#next for (self: ContainerIterator[nullable Object]) */
873 void abstract_collection__ContainerIterator__next(val
* self
) {
874 short int var
/* : Bool */;
876 self
->attrs
[COLOR_abstract_collection__ContainerIterator___is_ok
].s
= var
; /* _is_ok on <self:ContainerIterator[nullable Object]> */
879 /* method abstract_collection#ContainerIterator#next for (self: Object) */
880 void VIRTUAL_abstract_collection__ContainerIterator__next(val
* self
) {
881 abstract_collection__ContainerIterator__next(self
);
884 /* method abstract_collection#ContainerIterator#init for (self: ContainerIterator[nullable Object], Container[nullable Object]) */
885 void abstract_collection__ContainerIterator__init(val
* self
, val
* p0
) {
886 short int var
/* : Bool */;
889 const struct type
* type_struct
;
890 const char* var_class_name
;
891 val
* var_c
/* var c: Container[nullable Object] */;
892 /* Covariant cast for argument 0 (c) <p0:Container[nullable Object]> isa Container[ContainerIterator#0] */
893 /* <p0:Container[nullable Object]> isa Container[ContainerIterator#0] */
894 type_struct
= self
->type
->resolution_table
->types
[COLOR_abstract_collection__Containerabstract_collection__ContainerIterator_FT0
];
895 cltype
= type_struct
->color
;
896 idtype
= type_struct
->id
;
897 if(cltype
>= p0
->type
->table_size
) {
900 var
= p0
->type
->type_table
[cltype
] == idtype
;
903 var_class_name
= p0
== NULL ?
"null" : p0
->type
->name
;
904 fprintf(stderr
, "Runtime error: Cast failed. Expected `%s`, got `%s`", "Container[ContainerIterator#0]", var_class_name
);
905 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 192);
909 self
->attrs
[COLOR_abstract_collection__ContainerIterator___container
].val
= var_c
; /* _container on <self:ContainerIterator[nullable Object]> */
912 /* method abstract_collection#ContainerIterator#init for (self: Object, Container[nullable Object]) */
913 void VIRTUAL_abstract_collection__ContainerIterator__init(val
* self
, val
* p0
) {
914 abstract_collection__ContainerIterator__init(self
, p0
);
917 /* method abstract_collection#ContainerIterator#is_ok for (self: ContainerIterator[nullable Object]): Bool */
918 short int abstract_collection__ContainerIterator__is_ok(val
* self
) {
919 short int var
/* : Bool */;
920 short int var1
/* : Bool */;
921 var1
= self
->attrs
[COLOR_abstract_collection__ContainerIterator___is_ok
].s
; /* _is_ok on <self:ContainerIterator[nullable Object]> */
926 /* method abstract_collection#ContainerIterator#is_ok for (self: Object): Bool */
927 short int VIRTUAL_abstract_collection__ContainerIterator__is_ok(val
* self
) {
928 short int var
/* : Bool */;
929 short int var1
/* : Bool */;
930 var1
= abstract_collection__ContainerIterator__is_ok(self
);
935 /* method abstract_collection#RemovableCollection#clear for (self: RemovableCollection[nullable Object]) */
936 void abstract_collection__RemovableCollection__clear(val
* self
) {
937 const char* var_class_name
;
938 var_class_name
= self
== NULL ?
"null" : self
->type
->name
;
939 fprintf(stderr
, "Runtime error: Abstract method `%s` called on `%s`", "clear", var_class_name
);
940 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 202);
944 /* method abstract_collection#RemovableCollection#clear for (self: Object) */
945 void VIRTUAL_abstract_collection__RemovableCollection__clear(val
* self
) {
946 abstract_collection__RemovableCollection__clear(self
);
949 /* method abstract_collection#RemovableCollection#remove for (self: RemovableCollection[nullable Object], nullable Object) */
950 void abstract_collection__RemovableCollection__remove(val
* self
, val
* p0
) {
951 short int var
/* : Bool */;
954 const struct type
* type_struct
;
955 short int is_nullable
;
956 const char* var_class_name
;
957 const char* var_class_name1
;
958 /* Covariant cast for argument 0 (item) <p0:nullable Object> isa RemovableCollection#0 */
959 /* <p0:nullable Object> isa RemovableCollection#0 */
960 type_struct
= self
->type
->resolution_table
->types
[COLOR_abstract_collection__RemovableCollection_FT0
];
961 cltype
= type_struct
->color
;
962 idtype
= type_struct
->id
;
963 is_nullable
= type_struct
->is_nullable
;
967 if(cltype
>= p0
->type
->table_size
) {
970 var
= p0
->type
->type_table
[cltype
] == idtype
;
974 var_class_name
= p0
== NULL ?
"null" : p0
->type
->name
;
975 fprintf(stderr
, "Runtime error: Cast failed. Expected `%s`, got `%s`", "RemovableCollection#0", var_class_name
);
976 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 205);
979 var_class_name1
= self
== NULL ?
"null" : self
->type
->name
;
980 fprintf(stderr
, "Runtime error: Abstract method `%s` called on `%s`", "remove", var_class_name1
);
981 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 205);
985 /* method abstract_collection#RemovableCollection#remove for (self: Object, nullable Object) */
986 void VIRTUAL_abstract_collection__RemovableCollection__remove(val
* self
, val
* p0
) {
987 abstract_collection__RemovableCollection__remove(self
, p0
);
990 /* method abstract_collection#RemovableCollection#remove_all for (self: RemovableCollection[nullable Object], nullable Object) */
991 void abstract_collection__RemovableCollection__remove_all(val
* self
, val
* p0
) {
992 short int var
/* : Bool */;
995 const struct type
* type_struct
;
996 short int is_nullable
;
997 const char* var_class_name
;
998 val
* var_item
/* var item: nullable Object */;
999 short int var1
/* : Bool */;
1000 /* Covariant cast for argument 0 (item) <p0:nullable Object> isa RemovableCollection#0 */
1001 /* <p0:nullable Object> isa RemovableCollection#0 */
1002 type_struct
= self
->type
->resolution_table
->types
[COLOR_abstract_collection__RemovableCollection_FT0
];
1003 cltype
= type_struct
->color
;
1004 idtype
= type_struct
->id
;
1005 is_nullable
= type_struct
->is_nullable
;
1009 if(cltype
>= p0
->type
->table_size
) {
1012 var
= p0
->type
->type_table
[cltype
] == idtype
;
1016 var_class_name
= p0
== NULL ?
"null" : p0
->type
->name
;
1017 fprintf(stderr
, "Runtime error: Cast failed. Expected `%s`, got `%s`", "RemovableCollection#0", var_class_name
);
1018 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 208);
1023 var1
= ((short int (*)(val
*, val
*))(self
->class->vft
[COLOR_abstract_collection__Collection__has
]))(self
, var_item
) /* has on <self:RemovableCollection[nullable Object]>*/;
1025 ((void (*)(val
*, val
*))(self
->class->vft
[COLOR_abstract_collection__RemovableCollection__remove
]))(self
, var_item
) /* remove on <self:RemovableCollection[nullable Object]>*/;
1026 CONTINUE_label
: (void)0;
1028 BREAK_label
: (void)0;
1031 /* method abstract_collection#RemovableCollection#remove_all for (self: Object, nullable Object) */
1032 void VIRTUAL_abstract_collection__RemovableCollection__remove_all(val
* self
, val
* p0
) {
1033 abstract_collection__RemovableCollection__remove_all(self
, p0
);
1036 /* method abstract_collection#SimpleCollection#add for (self: SimpleCollection[nullable Object], nullable Object) */
1037 void abstract_collection__SimpleCollection__add(val
* self
, val
* p0
) {
1038 short int var
/* : Bool */;
1041 const struct type
* type_struct
;
1042 short int is_nullable
;
1043 const char* var_class_name
;
1044 const char* var_class_name1
;
1045 /* Covariant cast for argument 0 (item) <p0:nullable Object> isa SimpleCollection#0 */
1046 /* <p0:nullable Object> isa SimpleCollection#0 */
1047 type_struct
= self
->type
->resolution_table
->types
[COLOR_abstract_collection__SimpleCollection_FT0
];
1048 cltype
= type_struct
->color
;
1049 idtype
= type_struct
->id
;
1050 is_nullable
= type_struct
->is_nullable
;
1054 if(cltype
>= p0
->type
->table_size
) {
1057 var
= p0
->type
->type_table
[cltype
] == idtype
;
1061 var_class_name
= p0
== NULL ?
"null" : p0
->type
->name
;
1062 fprintf(stderr
, "Runtime error: Cast failed. Expected `%s`, got `%s`", "SimpleCollection#0", var_class_name
);
1063 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 215);
1066 var_class_name1
= self
== NULL ?
"null" : self
->type
->name
;
1067 fprintf(stderr
, "Runtime error: Abstract method `%s` called on `%s`", "add", var_class_name1
);
1068 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 215);
1072 /* method abstract_collection#SimpleCollection#add for (self: Object, nullable Object) */
1073 void VIRTUAL_abstract_collection__SimpleCollection__add(val
* self
, val
* p0
) {
1074 abstract_collection__SimpleCollection__add(self
, p0
);
1077 /* method abstract_collection#SimpleCollection#add_all for (self: SimpleCollection[nullable Object], Collection[nullable Object]) */
1078 void abstract_collection__SimpleCollection__add_all(val
* self
, val
* p0
) {
1079 short int var
/* : Bool */;
1082 const struct type
* type_struct
;
1083 const char* var_class_name
;
1084 val
* var_coll
/* var coll: Collection[nullable Object] */;
1085 val
* var1
/* : Iterator[nullable Object] */;
1086 short int var2
/* : Bool */;
1087 val
* var3
/* : nullable Object */;
1088 val
* var_i
/* var i: nullable Object */;
1089 /* Covariant cast for argument 0 (coll) <p0:Collection[nullable Object]> isa Collection[SimpleCollection#0] */
1090 /* <p0:Collection[nullable Object]> isa Collection[SimpleCollection#0] */
1091 type_struct
= self
->type
->resolution_table
->types
[COLOR_abstract_collection__Collectionabstract_collection__SimpleCollection_FT0
];
1092 cltype
= type_struct
->color
;
1093 idtype
= type_struct
->id
;
1094 if(cltype
>= p0
->type
->table_size
) {
1097 var
= p0
->type
->type_table
[cltype
] == idtype
;
1100 var_class_name
= p0
== NULL ?
"null" : p0
->type
->name
;
1101 fprintf(stderr
, "Runtime error: Cast failed. Expected `%s`, got `%s`", "Collection[SimpleCollection#0]", var_class_name
);
1102 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 219);
1106 var1
= ((val
* (*)(val
*))(var_coll
->class->vft
[COLOR_abstract_collection__Collection__iterator
]))(var_coll
) /* iterator on <var_coll:Collection[nullable Object]>*/;
1108 var2
= ((short int (*)(val
*))(var1
->class->vft
[COLOR_abstract_collection__Iterator__is_ok
]))(var1
) /* is_ok on <var1:Iterator[nullable Object]>*/;
1110 var3
= ((val
* (*)(val
*))(var1
->class->vft
[COLOR_abstract_collection__Iterator__item
]))(var1
) /* item on <var1:Iterator[nullable Object]>*/;
1112 ((void (*)(val
*, val
*))(self
->class->vft
[COLOR_abstract_collection__SimpleCollection__add
]))(self
, var_i
) /* add on <self:SimpleCollection[nullable Object]>*/;
1113 CONTINUE_label
: (void)0;
1114 ((void (*)(val
*))(var1
->class->vft
[COLOR_abstract_collection__Iterator__next
]))(var1
) /* next on <var1:Iterator[nullable Object]>*/;
1116 BREAK_label
: (void)0;
1119 /* method abstract_collection#SimpleCollection#add_all for (self: Object, Collection[nullable Object]) */
1120 void VIRTUAL_abstract_collection__SimpleCollection__add_all(val
* self
, val
* p0
) {
1121 abstract_collection__SimpleCollection__add_all(self
, p0
);
1124 /* method abstract_collection#Set#has_only for (self: Set[Object], Object): Bool */
1125 short int abstract_collection__Set__has_only(val
* self
, val
* p0
) {
1126 short int var
/* : Bool */;
1127 short int var1
/* : Bool */;
1130 const struct type
* type_struct
;
1131 const char* var_class_name
;
1132 val
* var_item
/* var item: Object */;
1133 long var2
/* : Int */;
1134 long var_l
/* var l: Int */;
1135 long var3
/* : Int */;
1136 short int var4
/* : Bool */;
1137 short int var6
/* : Bool */;
1138 short int var7
/* : Bool */;
1139 long var8
/* : Int */;
1140 short int var9
/* : Bool */;
1141 short int var11
/* : Bool */;
1142 short int var12
/* : Bool */;
1143 short int var13
/* : Bool */;
1144 /* Covariant cast for argument 0 (item) <p0:Object> isa Collection#0 */
1145 /* <p0:Object> isa Collection#0 */
1146 type_struct
= self
->type
->resolution_table
->types
[COLOR_abstract_collection__Collection_FT0
];
1147 cltype
= type_struct
->color
;
1148 idtype
= type_struct
->id
;
1149 if(cltype
>= p0
->type
->table_size
) {
1152 var1
= p0
->type
->type_table
[cltype
] == idtype
;
1155 var_class_name
= p0
== NULL ?
"null" : p0
->type
->name
;
1156 fprintf(stderr
, "Runtime error: Cast failed. Expected `%s`, got `%s`", "Collection#0", var_class_name
);
1157 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 235);
1161 var2
= ((long (*)(val
*))(self
->class->vft
[COLOR_abstract_collection__Collection__length
]))(self
) /* length on <self:Set[Object]>*/;
1164 { /* Inline kernel#Int#== (var_l,var3) */
1165 var6
= var_l
== var3
;
1171 var7
= ((short int (*)(val
*, val
*))(self
->class->vft
[COLOR_abstract_collection__Collection__has
]))(self
, var_item
) /* has on <self:Set[Object]>*/;
1176 { /* Inline kernel#Int#== (var_l,var8) */
1177 var11
= var_l
== var8
;
1180 RET_LABEL10
:(void)0;
1195 /* method abstract_collection#Set#has_only for (self: Object, nullable Object): Bool */
1196 short int VIRTUAL_abstract_collection__Set__has_only(val
* self
, val
* p0
) {
1197 short int var
/* : Bool */;
1198 short int var1
/* : Bool */;
1199 var1
= abstract_collection__Set__has_only(self
, p0
);
1204 /* method abstract_collection#Set#count for (self: Set[Object], Object): Int */
1205 long abstract_collection__Set__count(val
* self
, val
* p0
) {
1206 long var
/* : Int */;
1207 short int var1
/* : Bool */;
1210 const struct type
* type_struct
;
1211 const char* var_class_name
;
1212 val
* var_item
/* var item: Object */;
1213 short int var2
/* : Bool */;
1214 long var3
/* : Int */;
1215 long var4
/* : Int */;
1216 /* Covariant cast for argument 0 (item) <p0:Object> isa Collection#0 */
1217 /* <p0:Object> isa Collection#0 */
1218 type_struct
= self
->type
->resolution_table
->types
[COLOR_abstract_collection__Collection_FT0
];
1219 cltype
= type_struct
->color
;
1220 idtype
= type_struct
->id
;
1221 if(cltype
>= p0
->type
->table_size
) {
1224 var1
= p0
->type
->type_table
[cltype
] == idtype
;
1227 var_class_name
= p0
== NULL ?
"null" : p0
->type
->name
;
1228 fprintf(stderr
, "Runtime error: Cast failed. Expected `%s`, got `%s`", "Collection#0", var_class_name
);
1229 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 247);
1233 var2
= ((short int (*)(val
*, val
*))(self
->class->vft
[COLOR_abstract_collection__Collection__has
]))(self
, var_item
) /* has on <self:Set[Object]>*/;
1246 /* method abstract_collection#Set#count for (self: Object, nullable Object): Int */
1247 long VIRTUAL_abstract_collection__Set__count(val
* self
, val
* p0
) {
1248 long var
/* : Int */;
1249 long var1
/* : Int */;
1250 var1
= abstract_collection__Set__count(self
, p0
);
1255 /* method abstract_collection#Set#remove_all for (self: Set[Object], Object) */
1256 void abstract_collection__Set__remove_all(val
* self
, val
* p0
) {
1257 short int var
/* : Bool */;
1260 const struct type
* type_struct
;
1261 const char* var_class_name
;
1262 val
* var_item
/* var item: Object */;
1263 /* Covariant cast for argument 0 (item) <p0:Object> isa RemovableCollection#0 */
1264 /* <p0:Object> isa RemovableCollection#0 */
1265 type_struct
= self
->type
->resolution_table
->types
[COLOR_abstract_collection__RemovableCollection_FT0
];
1266 cltype
= type_struct
->color
;
1267 idtype
= type_struct
->id
;
1268 if(cltype
>= p0
->type
->table_size
) {
1271 var
= p0
->type
->type_table
[cltype
] == idtype
;
1274 var_class_name
= p0
== NULL ?
"null" : p0
->type
->name
;
1275 fprintf(stderr
, "Runtime error: Cast failed. Expected `%s`, got `%s`", "RemovableCollection#0", var_class_name
);
1276 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 257);
1280 ((void (*)(val
*, val
*))(self
->class->vft
[COLOR_abstract_collection__RemovableCollection__remove
]))(self
, var_item
) /* remove on <self:Set[Object]>*/;
1283 /* method abstract_collection#Set#remove_all for (self: Object, nullable Object) */
1284 void VIRTUAL_abstract_collection__Set__remove_all(val
* self
, val
* p0
) {
1285 abstract_collection__Set__remove_all(self
, p0
);
1288 /* method abstract_collection#Set#== for (self: Set[Object], nullable Object): Bool */
1289 short int abstract_collection__Set___61d_61d(val
* self
, val
* p0
) {
1290 short int var
/* : Bool */;
1291 val
* var_other
/* var other: nullable Object */;
1292 short int var1
/* : Bool */;
1295 short int var2
/* : Bool */;
1296 short int var3
/* : Bool */;
1297 long var4
/* : Int */;
1298 long var5
/* : Int */;
1299 short int var6
/* : Bool */;
1300 short int var8
/* : Bool */;
1301 short int var9
/* : Bool */;
1302 short int var10
/* : Bool */;
1303 short int var11
/* : Bool */;
1306 const struct type
* type_struct
;
1307 const char* var_class_name
;
1308 short int var14
/* : Bool */;
1310 /* <var_other:nullable Object> isa Set[Object] */
1311 cltype
= type_abstract_collection__Setkernel__Object
.color
;
1312 idtype
= type_abstract_collection__Setkernel__Object
.id
;
1313 if(var_other
== NULL
) {
1316 if(cltype
>= var_other
->type
->table_size
) {
1319 var1
= var_other
->type
->type_table
[cltype
] == idtype
;
1329 var4
= ((long (*)(val
*))(var_other
->class->vft
[COLOR_abstract_collection__Collection__length
]))(var_other
) /* length on <var_other:nullable Object(Set[Object])>*/;
1330 var5
= ((long (*)(val
*))(self
->class->vft
[COLOR_abstract_collection__Collection__length
]))(self
) /* length on <self:Set[Object]>*/;
1331 { /* Inline kernel#Int#!= (var4,var5) */
1332 var8
= var4
== var5
;
1344 /* <var_other:nullable Object(Set[Object])> isa Collection[Set#0] */
1345 type_struct
= self
->type
->resolution_table
->types
[COLOR_abstract_collection__Collectionabstract_collection__Set_FT0
];
1346 cltype12
= type_struct
->color
;
1347 idtype13
= type_struct
->id
;
1348 if(cltype12
>= var_other
->type
->table_size
) {
1351 var11
= var_other
->type
->type_table
[cltype12
] == idtype13
;
1354 var_class_name
= var_other
== NULL ?
"null" : var_other
->type
->name
;
1355 fprintf(stderr
, "Runtime error: Cast failed. Expected `%s`, got `%s`", "Collection[Set#0]", var_class_name
);
1356 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 265);
1359 var14
= ((short int (*)(val
*, val
*))(self
->class->vft
[COLOR_abstract_collection__Collection__has_all
]))(self
, var_other
) /* has_all on <self:Set[Object]>*/;
1365 /* method abstract_collection#Set#== for (self: Object, nullable Object): Bool */
1366 short int VIRTUAL_abstract_collection__Set___61d_61d(val
* self
, val
* p0
) {
1367 short int var
/* : Bool */;
1368 short int var1
/* : Bool */;
1369 var1
= abstract_collection__Set___61d_61d(self
, p0
);
1374 /* method abstract_collection#Set#hash for (self: Set[Object]): Int */
1375 long abstract_collection__Set__hash(val
* self
) {
1376 long var
/* : Int */;
1377 long var1
/* : Int */;
1378 long var_res
/* var res: Int */;
1379 val
* var2
/* : Iterator[nullable Object] */;
1380 short int var3
/* : Bool */;
1381 val
* var4
/* : nullable Object */;
1382 val
* var_e
/* var e: Object */;
1383 long var5
/* : Int */;
1384 long var6
/* : Int */;
1385 long var8
/* : Int */;
1388 var2
= ((val
* (*)(val
*))(self
->class->vft
[COLOR_abstract_collection__Collection__iterator
]))(self
) /* iterator on <self:Set[Object]>*/;
1390 var3
= ((short int (*)(val
*))(var2
->class->vft
[COLOR_abstract_collection__Iterator__is_ok
]))(var2
) /* is_ok on <var2:Iterator[nullable Object]>*/;
1392 var4
= ((val
* (*)(val
*))(var2
->class->vft
[COLOR_abstract_collection__Iterator__item
]))(var2
) /* item on <var2:Iterator[nullable Object]>*/;
1394 var5
= kernel__Int__hash(var_res
);
1395 { /* Inline kernel#Int#+ (var_res,var5) */
1396 var8
= var_res
+ var5
;
1402 CONTINUE_label
: (void)0;
1403 ((void (*)(val
*))(var2
->class->vft
[COLOR_abstract_collection__Iterator__next
]))(var2
) /* next on <var2:Iterator[nullable Object]>*/;
1405 BREAK_label
: (void)0;
1411 /* method abstract_collection#Set#hash for (self: Object): Int */
1412 long VIRTUAL_abstract_collection__Set__hash(val
* self
) {
1413 long var
/* : Int */;
1414 long var1
/* : Int */;
1415 var1
= abstract_collection__Set__hash(self
);
1420 /* method abstract_collection#MapRead#[] for (self: MapRead[Object, nullable Object], Object): nullable Object */
1421 val
* abstract_collection__MapRead___91d_93d(val
* self
, val
* p0
) {
1422 val
* var
/* : nullable Object */;
1423 short int var1
/* : Bool */;
1426 const struct type
* type_struct
;
1427 const char* var_class_name
;
1428 const char* var_class_name2
;
1429 /* Covariant cast for argument 0 (key) <p0:Object> isa MapRead#0 */
1430 /* <p0:Object> isa MapRead#0 */
1431 type_struct
= self
->type
->resolution_table
->types
[COLOR_abstract_collection__MapRead_FT0
];
1432 cltype
= type_struct
->color
;
1433 idtype
= type_struct
->id
;
1434 if(cltype
>= p0
->type
->table_size
) {
1437 var1
= p0
->type
->type_table
[cltype
] == idtype
;
1440 var_class_name
= p0
== NULL ?
"null" : p0
->type
->name
;
1441 fprintf(stderr
, "Runtime error: Cast failed. Expected `%s`, got `%s`", "MapRead#0", var_class_name
);
1442 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 279);
1445 var_class_name2
= self
== NULL ?
"null" : self
->type
->name
;
1446 fprintf(stderr
, "Runtime error: Abstract method `%s` called on `%s`", "[]", var_class_name2
);
1447 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 279);
1452 /* method abstract_collection#MapRead#[] for (self: Object, Object): nullable Object */
1453 val
* VIRTUAL_abstract_collection__MapRead___91d_93d(val
* self
, val
* p0
) {
1454 val
* var
/* : nullable Object */;
1455 val
* var1
/* : nullable Object */;
1456 var1
= abstract_collection__MapRead___91d_93d(self
, p0
);
1461 /* method abstract_collection#MapRead#get_or_default for (self: MapRead[Object, nullable Object], Object, nullable Object): nullable Object */
1462 val
* abstract_collection__MapRead__get_or_default(val
* self
, val
* p0
, val
* p1
) {
1463 val
* var
/* : nullable Object */;
1464 short int var1
/* : Bool */;
1467 const struct type
* type_struct
;
1468 const char* var_class_name
;
1469 short int var2
/* : Bool */;
1472 const struct type
* type_struct5
;
1473 short int is_nullable
;
1474 const char* var_class_name6
;
1475 val
* var_key
/* var key: Object */;
1476 val
* var_default
/* var default: nullable Object */;
1477 short int var7
/* : Bool */;
1478 val
* var8
/* : nullable Object */;
1479 /* Covariant cast for argument 0 (key) <p0:Object> isa MapRead#0 */
1480 /* <p0:Object> isa MapRead#0 */
1481 type_struct
= self
->type
->resolution_table
->types
[COLOR_abstract_collection__MapRead_FT0
];
1482 cltype
= type_struct
->color
;
1483 idtype
= type_struct
->id
;
1484 if(cltype
>= p0
->type
->table_size
) {
1487 var1
= p0
->type
->type_table
[cltype
] == idtype
;
1490 var_class_name
= p0
== NULL ?
"null" : p0
->type
->name
;
1491 fprintf(stderr
, "Runtime error: Cast failed. Expected `%s`, got `%s`", "MapRead#0", var_class_name
);
1492 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 282);
1495 /* Covariant cast for argument 1 (default) <p1:nullable Object> isa MapRead#1 */
1496 /* <p1:nullable Object> isa MapRead#1 */
1497 type_struct5
= self
->type
->resolution_table
->types
[COLOR_abstract_collection__MapRead_FT1
];
1498 cltype3
= type_struct5
->color
;
1499 idtype4
= type_struct5
->id
;
1500 is_nullable
= type_struct5
->is_nullable
;
1504 if(cltype3
>= p1
->type
->table_size
) {
1507 var2
= p1
->type
->type_table
[cltype3
] == idtype4
;
1511 var_class_name6
= p1
== NULL ?
"null" : p1
->type
->name
;
1512 fprintf(stderr
, "Runtime error: Cast failed. Expected `%s`, got `%s`", "MapRead#1", var_class_name6
);
1513 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 282);
1518 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]>*/;
1520 var8
= ((val
* (*)(val
*, val
*))(self
->class->vft
[COLOR_abstract_collection__MapRead___91d_93d
]))(self
, var_key
) /* [] on <self:MapRead[Object, nullable Object]>*/;
1530 /* method abstract_collection#MapRead#get_or_default for (self: Object, Object, nullable Object): nullable Object */
1531 val
* VIRTUAL_abstract_collection__MapRead__get_or_default(val
* self
, val
* p0
, val
* p1
) {
1532 val
* var
/* : nullable Object */;
1533 val
* var1
/* : nullable Object */;
1534 var1
= abstract_collection__MapRead__get_or_default(self
, p0
, p1
);
1539 /* method abstract_collection#MapRead#has_key for (self: MapRead[Object, nullable Object], Object): Bool */
1540 short int abstract_collection__MapRead__has_key(val
* self
, val
* p0
) {
1541 short int var
/* : Bool */;
1542 short int var1
/* : Bool */;
1545 const struct type
* type_struct
;
1546 const char* var_class_name
;
1547 val
* var_key
/* var key: Object */;
1548 val
* var2
/* : Collection[Object] */;
1549 short int var3
/* : Bool */;
1550 /* Covariant cast for argument 0 (key) <p0:Object> isa MapRead#0 */
1551 /* <p0:Object> isa MapRead#0 */
1552 type_struct
= self
->type
->resolution_table
->types
[COLOR_abstract_collection__MapRead_FT0
];
1553 cltype
= type_struct
->color
;
1554 idtype
= type_struct
->id
;
1555 if(cltype
>= p0
->type
->table_size
) {
1558 var1
= p0
->type
->type_table
[cltype
] == idtype
;
1561 var_class_name
= p0
== NULL ?
"null" : p0
->type
->name
;
1562 fprintf(stderr
, "Runtime error: Cast failed. Expected `%s`, got `%s`", "MapRead#0", var_class_name
);
1563 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 289);
1567 var2
= ((val
* (*)(val
*))(self
->class->vft
[COLOR_abstract_collection__MapRead__keys
]))(self
) /* keys on <self:MapRead[Object, nullable Object]>*/;
1568 var3
= ((short int (*)(val
*, val
*))(var2
->class->vft
[COLOR_abstract_collection__Collection__has
]))(var2
, var_key
) /* has on <var2:Collection[Object]>*/;
1574 /* method abstract_collection#MapRead#has_key for (self: Object, Object): Bool */
1575 short int VIRTUAL_abstract_collection__MapRead__has_key(val
* self
, val
* p0
) {
1576 short int var
/* : Bool */;
1577 short int var1
/* : Bool */;
1578 var1
= abstract_collection__MapRead__has_key(self
, p0
);
1583 /* method abstract_collection#MapRead#iterator for (self: MapRead[Object, nullable Object]): MapIterator[Object, nullable Object] */
1584 val
* abstract_collection__MapRead__iterator(val
* self
) {
1585 val
* var
/* : MapIterator[Object, nullable Object] */;
1586 const char* var_class_name
;
1587 var_class_name
= self
== NULL ?
"null" : self
->type
->name
;
1588 fprintf(stderr
, "Runtime error: Abstract method `%s` called on `%s`", "iterator", var_class_name
);
1589 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 292);
1594 /* method abstract_collection#MapRead#iterator for (self: Object): MapIterator[Object, nullable Object] */
1595 val
* VIRTUAL_abstract_collection__MapRead__iterator(val
* self
) {
1596 val
* var
/* : MapIterator[Object, nullable Object] */;
1597 val
* var1
/* : MapIterator[Object, nullable Object] */;
1598 var1
= abstract_collection__MapRead__iterator(self
);
1603 /* method abstract_collection#MapRead#values for (self: MapRead[Object, nullable Object]): Collection[nullable Object] */
1604 val
* abstract_collection__MapRead__values(val
* self
) {
1605 val
* var
/* : Collection[nullable Object] */;
1606 const char* var_class_name
;
1607 var_class_name
= self
== NULL ?
"null" : self
->type
->name
;
1608 fprintf(stderr
, "Runtime error: Abstract method `%s` called on `%s`", "values", var_class_name
);
1609 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 295);
1614 /* method abstract_collection#MapRead#values for (self: Object): Collection[nullable Object] */
1615 val
* VIRTUAL_abstract_collection__MapRead__values(val
* self
) {
1616 val
* var
/* : Collection[nullable Object] */;
1617 val
* var1
/* : Collection[nullable Object] */;
1618 var1
= abstract_collection__MapRead__values(self
);
1623 /* method abstract_collection#MapRead#keys for (self: MapRead[Object, nullable Object]): Collection[Object] */
1624 val
* abstract_collection__MapRead__keys(val
* self
) {
1625 val
* var
/* : Collection[Object] */;
1626 const char* var_class_name
;
1627 var_class_name
= self
== NULL ?
"null" : self
->type
->name
;
1628 fprintf(stderr
, "Runtime error: Abstract method `%s` called on `%s`", "keys", var_class_name
);
1629 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 300);
1634 /* method abstract_collection#MapRead#keys for (self: Object): Collection[Object] */
1635 val
* VIRTUAL_abstract_collection__MapRead__keys(val
* self
) {
1636 val
* var
/* : Collection[Object] */;
1637 val
* var1
/* : Collection[Object] */;
1638 var1
= abstract_collection__MapRead__keys(self
);
1643 /* method abstract_collection#MapRead#is_empty for (self: MapRead[Object, nullable Object]): Bool */
1644 short int abstract_collection__MapRead__is_empty(val
* self
) {
1645 short int var
/* : Bool */;
1646 const char* var_class_name
;
1647 var_class_name
= self
== NULL ?
"null" : self
->type
->name
;
1648 fprintf(stderr
, "Runtime error: Abstract method `%s` called on `%s`", "is_empty", var_class_name
);
1649 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 305);
1654 /* method abstract_collection#MapRead#is_empty for (self: Object): Bool */
1655 short int VIRTUAL_abstract_collection__MapRead__is_empty(val
* self
) {
1656 short int var
/* : Bool */;
1657 short int var1
/* : Bool */;
1658 var1
= abstract_collection__MapRead__is_empty(self
);
1663 /* method abstract_collection#MapRead#length for (self: MapRead[Object, nullable Object]): Int */
1664 long abstract_collection__MapRead__length(val
* self
) {
1665 long var
/* : Int */;
1666 const char* var_class_name
;
1667 var_class_name
= self
== NULL ?
"null" : self
->type
->name
;
1668 fprintf(stderr
, "Runtime error: Abstract method `%s` called on `%s`", "length", var_class_name
);
1669 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 308);
1674 /* method abstract_collection#MapRead#length for (self: Object): Int */
1675 long VIRTUAL_abstract_collection__MapRead__length(val
* self
) {
1676 long var
/* : Int */;
1677 long var1
/* : Int */;
1678 var1
= abstract_collection__MapRead__length(self
);
1683 /* method abstract_collection#Map#[]= for (self: Map[Object, nullable Object], Object, nullable Object) */
1684 void abstract_collection__Map___91d_93d_61d(val
* self
, val
* p0
, val
* p1
) {
1685 short int var
/* : Bool */;
1688 const struct type
* type_struct
;
1689 const char* var_class_name
;
1690 short int var1
/* : Bool */;
1693 const struct type
* type_struct4
;
1694 short int is_nullable
;
1695 const char* var_class_name5
;
1696 const char* var_class_name6
;
1697 /* Covariant cast for argument 0 (key) <p0:Object> isa Map#0 */
1698 /* <p0:Object> isa Map#0 */
1699 type_struct
= self
->type
->resolution_table
->types
[COLOR_abstract_collection__Map_FT0
];
1700 cltype
= type_struct
->color
;
1701 idtype
= type_struct
->id
;
1702 if(cltype
>= p0
->type
->table_size
) {
1705 var
= p0
->type
->type_table
[cltype
] == idtype
;
1708 var_class_name
= p0
== NULL ?
"null" : p0
->type
->name
;
1709 fprintf(stderr
, "Runtime error: Cast failed. Expected `%s`, got `%s`", "Map#0", var_class_name
);
1710 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 338);
1713 /* Covariant cast for argument 1 (item) <p1:nullable Object> isa Map#1 */
1714 /* <p1:nullable Object> isa Map#1 */
1715 type_struct4
= self
->type
->resolution_table
->types
[COLOR_abstract_collection__Map_FT1
];
1716 cltype2
= type_struct4
->color
;
1717 idtype3
= type_struct4
->id
;
1718 is_nullable
= type_struct4
->is_nullable
;
1722 if(cltype2
>= p1
->type
->table_size
) {
1725 var1
= p1
->type
->type_table
[cltype2
] == idtype3
;
1729 var_class_name5
= p1
== NULL ?
"null" : p1
->type
->name
;
1730 fprintf(stderr
, "Runtime error: Cast failed. Expected `%s`, got `%s`", "Map#1", var_class_name5
);
1731 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 338);
1734 var_class_name6
= self
== NULL ?
"null" : self
->type
->name
;
1735 fprintf(stderr
, "Runtime error: Abstract method `%s` called on `%s`", "[]=", var_class_name6
);
1736 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 338);
1740 /* method abstract_collection#Map#[]= for (self: Object, Object, nullable Object) */
1741 void VIRTUAL_abstract_collection__Map___91d_93d_61d(val
* self
, val
* p0
, val
* p1
) {
1742 abstract_collection__Map___91d_93d_61d(self
, p0
, p1
);
1745 /* method abstract_collection#Map#recover_with for (self: Map[Object, nullable Object], Map[Object, nullable Object]) */
1746 void abstract_collection__Map__recover_with(val
* self
, val
* p0
) {
1747 short int var
/* : Bool */;
1750 const struct type
* type_struct
;
1751 const char* var_class_name
;
1752 val
* var_map
/* var map: Map[Object, nullable Object] */;
1753 val
* var1
/* : MapIterator[Object, nullable Object] */;
1754 val
* var_i
/* var i: MapIterator[Object, nullable Object] */;
1755 short int var2
/* : Bool */;
1756 val
* var3
/* : Object */;
1757 val
* var4
/* : nullable Object */;
1758 /* Covariant cast for argument 0 (map) <p0:Map[Object, nullable Object]> isa Map[Map#0, Map#1] */
1759 /* <p0:Map[Object, nullable Object]> isa Map[Map#0, Map#1] */
1760 type_struct
= self
->type
->resolution_table
->types
[COLOR_abstract_collection__Mapabstract_collection__Map_FT0abstract_collection__Map_FT1
];
1761 cltype
= type_struct
->color
;
1762 idtype
= type_struct
->id
;
1763 if(cltype
>= p0
->type
->table_size
) {
1766 var
= p0
->type
->type_table
[cltype
] == idtype
;
1769 var_class_name
= p0
== NULL ?
"null" : p0
->type
->name
;
1770 fprintf(stderr
, "Runtime error: Cast failed. Expected `%s`, got `%s`", "Map[Map#0, Map#1]", var_class_name
);
1771 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 341);
1775 var1
= ((val
* (*)(val
*))(var_map
->class->vft
[COLOR_abstract_collection__MapRead__iterator
]))(var_map
) /* iterator on <var_map:Map[Object, nullable Object]>*/;
1778 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]>*/;
1780 var3
= ((val
* (*)(val
*))(var_i
->class->vft
[COLOR_abstract_collection__MapIterator__key
]))(var_i
) /* key on <var_i:MapIterator[Object, nullable Object]>*/;
1781 var4
= ((val
* (*)(val
*))(var_i
->class->vft
[COLOR_abstract_collection__MapIterator__item
]))(var_i
) /* item on <var_i:MapIterator[Object, nullable Object]>*/;
1782 ((void (*)(val
*, val
*, val
*))(self
->class->vft
[COLOR_abstract_collection__Map___91d_93d_61d
]))(self
, var3
, var4
) /* []= on <self:Map[Object, nullable Object]>*/;
1783 ((void (*)(val
*))(var_i
->class->vft
[COLOR_abstract_collection__MapIterator__next
]))(var_i
) /* next on <var_i:MapIterator[Object, nullable Object]>*/;
1784 CONTINUE_label
: (void)0;
1786 BREAK_label
: (void)0;
1789 /* method abstract_collection#Map#recover_with for (self: Object, Map[Object, nullable Object]) */
1790 void VIRTUAL_abstract_collection__Map__recover_with(val
* self
, val
* p0
) {
1791 abstract_collection__Map__recover_with(self
, p0
);
1794 /* method abstract_collection#Map#clear for (self: Map[Object, nullable Object]) */
1795 void abstract_collection__Map__clear(val
* self
) {
1796 const char* var_class_name
;
1797 var_class_name
= self
== NULL ?
"null" : self
->type
->name
;
1798 fprintf(stderr
, "Runtime error: Abstract method `%s` called on `%s`", "clear", var_class_name
);
1799 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 352);
1803 /* method abstract_collection#Map#clear for (self: Object) */
1804 void VIRTUAL_abstract_collection__Map__clear(val
* self
) {
1805 abstract_collection__Map__clear(self
);
1808 /* method abstract_collection#Map#values for (self: Map[Object, nullable Object]): RemovableCollection[nullable Object] */
1809 val
* abstract_collection__Map__values(val
* self
) {
1810 val
* var
/* : RemovableCollection[nullable Object] */;
1811 const char* var_class_name
;
1812 var_class_name
= self
== NULL ?
"null" : self
->type
->name
;
1813 fprintf(stderr
, "Runtime error: Abstract method `%s` called on `%s`", "values", var_class_name
);
1814 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 355);
1819 /* method abstract_collection#Map#values for (self: Object): Collection[nullable Object] */
1820 val
* VIRTUAL_abstract_collection__Map__values(val
* self
) {
1821 val
* var
/* : Collection[nullable Object] */;
1822 val
* var1
/* : RemovableCollection[nullable Object] */;
1823 var1
= abstract_collection__Map__values(self
);
1828 /* method abstract_collection#Map#keys for (self: Map[Object, nullable Object]): RemovableCollection[Object] */
1829 val
* abstract_collection__Map__keys(val
* self
) {
1830 val
* var
/* : RemovableCollection[Object] */;
1831 const char* var_class_name
;
1832 var_class_name
= self
== NULL ?
"null" : self
->type
->name
;
1833 fprintf(stderr
, "Runtime error: Abstract method `%s` called on `%s`", "keys", var_class_name
);
1834 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 357);
1839 /* method abstract_collection#Map#keys for (self: Object): Collection[Object] */
1840 val
* VIRTUAL_abstract_collection__Map__keys(val
* self
) {
1841 val
* var
/* : Collection[Object] */;
1842 val
* var1
/* : RemovableCollection[Object] */;
1843 var1
= abstract_collection__Map__keys(self
);
1848 /* method abstract_collection#MapIterator#item for (self: MapIterator[Object, nullable Object]): nullable Object */
1849 val
* abstract_collection__MapIterator__item(val
* self
) {
1850 val
* var
/* : nullable Object */;
1851 const char* var_class_name
;
1852 var_class_name
= self
== NULL ?
"null" : self
->type
->name
;
1853 fprintf(stderr
, "Runtime error: Abstract method `%s` called on `%s`", "item", var_class_name
);
1854 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 362);
1859 /* method abstract_collection#MapIterator#item for (self: Object): nullable Object */
1860 val
* VIRTUAL_abstract_collection__MapIterator__item(val
* self
) {
1861 val
* var
/* : nullable Object */;
1862 val
* var1
/* : nullable Object */;
1863 var1
= abstract_collection__MapIterator__item(self
);
1868 /* method abstract_collection#MapIterator#key for (self: MapIterator[Object, nullable Object]): Object */
1869 val
* abstract_collection__MapIterator__key(val
* self
) {
1870 val
* var
/* : Object */;
1871 const char* var_class_name
;
1872 var_class_name
= self
== NULL ?
"null" : self
->type
->name
;
1873 fprintf(stderr
, "Runtime error: Abstract method `%s` called on `%s`", "key", var_class_name
);
1874 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 366);
1879 /* method abstract_collection#MapIterator#key for (self: Object): Object */
1880 val
* VIRTUAL_abstract_collection__MapIterator__key(val
* self
) {
1881 val
* var
/* : Object */;
1882 val
* var1
/* : Object */;
1883 var1
= abstract_collection__MapIterator__key(self
);
1888 /* method abstract_collection#MapIterator#next for (self: MapIterator[Object, nullable Object]) */
1889 void abstract_collection__MapIterator__next(val
* self
) {
1890 const char* var_class_name
;
1891 var_class_name
= self
== NULL ?
"null" : self
->type
->name
;
1892 fprintf(stderr
, "Runtime error: Abstract method `%s` called on `%s`", "next", var_class_name
);
1893 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 370);
1897 /* method abstract_collection#MapIterator#next for (self: Object) */
1898 void VIRTUAL_abstract_collection__MapIterator__next(val
* self
) {
1899 abstract_collection__MapIterator__next(self
);
1902 /* method abstract_collection#MapIterator#is_ok for (self: MapIterator[Object, nullable Object]): Bool */
1903 short int abstract_collection__MapIterator__is_ok(val
* self
) {
1904 short int var
/* : Bool */;
1905 const char* var_class_name
;
1906 var_class_name
= self
== NULL ?
"null" : self
->type
->name
;
1907 fprintf(stderr
, "Runtime error: Abstract method `%s` called on `%s`", "is_ok", var_class_name
);
1908 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 374);
1913 /* method abstract_collection#MapIterator#is_ok for (self: Object): Bool */
1914 short int VIRTUAL_abstract_collection__MapIterator__is_ok(val
* self
) {
1915 short int var
/* : Bool */;
1916 short int var1
/* : Bool */;
1917 var1
= abstract_collection__MapIterator__is_ok(self
);
1922 /* method abstract_collection#MapKeysIterator#iterator for (self: MapKeysIterator[Object, nullable Object]): MapIterator[Object, nullable Object] */
1923 val
* abstract_collection__MapKeysIterator__iterator(val
* self
) {
1924 val
* var
/* : MapIterator[Object, nullable Object] */;
1925 val
* var1
/* : MapIterator[Object, nullable Object] */;
1926 var1
= self
->attrs
[COLOR_abstract_collection__MapKeysIterator___64diterator
].val
; /* @iterator on <self:MapKeysIterator[Object, nullable Object]> */
1928 fprintf(stderr
, "Runtime error: %s", "Uninitialized attribute @iterator");
1929 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 384);
1936 /* method abstract_collection#MapKeysIterator#iterator for (self: Object): MapIterator[Object, nullable Object] */
1937 val
* VIRTUAL_abstract_collection__MapKeysIterator__iterator(val
* self
) {
1938 val
* var
/* : MapIterator[Object, nullable Object] */;
1939 val
* var1
/* : MapIterator[Object, nullable Object] */;
1940 var1
= abstract_collection__MapKeysIterator__iterator(self
);
1945 /* method abstract_collection#MapKeysIterator#iterator= for (self: MapKeysIterator[Object, nullable Object], MapIterator[Object, nullable Object]) */
1946 void abstract_collection__MapKeysIterator__iterator_61d(val
* self
, val
* p0
) {
1947 short int var
/* : Bool */;
1950 const struct type
* type_struct
;
1951 const char* var_class_name
;
1952 /* Covariant cast for argument 0 (iterator) <p0:MapIterator[Object, nullable Object]> isa MapIterator[MapKeysIterator#0, MapKeysIterator#1] */
1953 /* <p0:MapIterator[Object, nullable Object]> isa MapIterator[MapKeysIterator#0, MapKeysIterator#1] */
1954 type_struct
= self
->type
->resolution_table
->types
[COLOR_abstract_collection__MapIteratorabstract_collection__MapKeysIterator_FT0abstract_collection__MapKeysIterator_FT1
];
1955 cltype
= type_struct
->color
;
1956 idtype
= type_struct
->id
;
1957 if(cltype
>= p0
->type
->table_size
) {
1960 var
= p0
->type
->type_table
[cltype
] == idtype
;
1963 var_class_name
= p0
== NULL ?
"null" : p0
->type
->name
;
1964 fprintf(stderr
, "Runtime error: Cast failed. Expected `%s`, got `%s`", "MapIterator[MapKeysIterator#0, MapKeysIterator#1]", var_class_name
);
1965 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 384);
1968 self
->attrs
[COLOR_abstract_collection__MapKeysIterator___64diterator
].val
= p0
; /* @iterator on <self:MapKeysIterator[Object, nullable Object]> */
1971 /* method abstract_collection#MapKeysIterator#iterator= for (self: Object, MapIterator[Object, nullable Object]) */
1972 void VIRTUAL_abstract_collection__MapKeysIterator__iterator_61d(val
* self
, val
* p0
) {
1973 abstract_collection__MapKeysIterator__iterator_61d(self
, p0
);
1976 /* method abstract_collection#MapKeysIterator#is_ok for (self: MapKeysIterator[Object, nullable Object]): Bool */
1977 short int abstract_collection__MapKeysIterator__is_ok(val
* self
) {
1978 short int var
/* : Bool */;
1979 val
* var1
/* : MapIterator[Object, nullable Object] */;
1980 short int var2
/* : Bool */;
1981 var1
= ((val
* (*)(val
*))(self
->class->vft
[COLOR_abstract_collection__MapKeysIterator__iterator
]))(self
) /* iterator on <self:MapKeysIterator[Object, nullable Object]>*/;
1982 var2
= ((short int (*)(val
*))(var1
->class->vft
[COLOR_abstract_collection__MapIterator__is_ok
]))(var1
) /* is_ok on <var1:MapIterator[Object, nullable Object]>*/;
1988 /* method abstract_collection#MapKeysIterator#is_ok for (self: Object): Bool */
1989 short int VIRTUAL_abstract_collection__MapKeysIterator__is_ok(val
* self
) {
1990 short int var
/* : Bool */;
1991 short int var1
/* : Bool */;
1992 var1
= abstract_collection__MapKeysIterator__is_ok(self
);
1997 /* method abstract_collection#MapKeysIterator#next for (self: MapKeysIterator[Object, nullable Object]) */
1998 void abstract_collection__MapKeysIterator__next(val
* self
) {
1999 val
* var
/* : MapIterator[Object, nullable Object] */;
2000 var
= ((val
* (*)(val
*))(self
->class->vft
[COLOR_abstract_collection__MapKeysIterator__iterator
]))(self
) /* iterator on <self:MapKeysIterator[Object, nullable Object]>*/;
2001 ((void (*)(val
*))(var
->class->vft
[COLOR_abstract_collection__MapIterator__next
]))(var
) /* next on <var:MapIterator[Object, nullable Object]>*/;
2004 /* method abstract_collection#MapKeysIterator#next for (self: Object) */
2005 void VIRTUAL_abstract_collection__MapKeysIterator__next(val
* self
) {
2006 abstract_collection__MapKeysIterator__next(self
);
2009 /* method abstract_collection#MapKeysIterator#item for (self: MapKeysIterator[Object, nullable Object]): Object */
2010 val
* abstract_collection__MapKeysIterator__item(val
* self
) {
2011 val
* var
/* : Object */;
2012 val
* var1
/* : MapIterator[Object, nullable Object] */;
2013 val
* var2
/* : Object */;
2014 var1
= ((val
* (*)(val
*))(self
->class->vft
[COLOR_abstract_collection__MapKeysIterator__iterator
]))(self
) /* iterator on <self:MapKeysIterator[Object, nullable Object]>*/;
2015 var2
= ((val
* (*)(val
*))(var1
->class->vft
[COLOR_abstract_collection__MapIterator__key
]))(var1
) /* key on <var1:MapIterator[Object, nullable Object]>*/;
2021 /* method abstract_collection#MapKeysIterator#item for (self: Object): nullable Object */
2022 val
* VIRTUAL_abstract_collection__MapKeysIterator__item(val
* self
) {
2023 val
* var
/* : nullable Object */;
2024 val
* var1
/* : Object */;
2025 var1
= abstract_collection__MapKeysIterator__item(self
);
2030 /* method abstract_collection#MapKeysIterator#init for (self: MapKeysIterator[Object, nullable Object], MapIterator[Object, nullable Object]) */
2031 void abstract_collection__MapKeysIterator__init(val
* self
, val
* p0
) {
2032 short int var
/* : Bool */;
2035 const struct type
* type_struct
;
2036 const char* var_class_name
;
2037 /* Covariant cast for argument 0 (iterator) <p0:MapIterator[Object, nullable Object]> isa MapIterator[MapKeysIterator#0, MapKeysIterator#1] */
2038 /* <p0:MapIterator[Object, nullable Object]> isa MapIterator[MapKeysIterator#0, MapKeysIterator#1] */
2039 type_struct
= self
->type
->resolution_table
->types
[COLOR_abstract_collection__MapIteratorabstract_collection__MapKeysIterator_FT0abstract_collection__MapKeysIterator_FT1
];
2040 cltype
= type_struct
->color
;
2041 idtype
= type_struct
->id
;
2042 if(cltype
>= p0
->type
->table_size
) {
2045 var
= p0
->type
->type_table
[cltype
] == idtype
;
2048 var_class_name
= p0
== NULL ?
"null" : p0
->type
->name
;
2049 fprintf(stderr
, "Runtime error: Cast failed. Expected `%s`, got `%s`", "MapIterator[MapKeysIterator#0, MapKeysIterator#1]", var_class_name
);
2050 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 381);
2053 self
->attrs
[COLOR_abstract_collection__MapKeysIterator___64diterator
].val
= p0
; /* @iterator on <self:MapKeysIterator[Object, nullable Object]> */
2056 /* method abstract_collection#MapKeysIterator#init for (self: Object, MapIterator[Object, nullable Object]) */
2057 void VIRTUAL_abstract_collection__MapKeysIterator__init(val
* self
, val
* p0
) {
2058 abstract_collection__MapKeysIterator__init(self
, p0
);
2061 /* method abstract_collection#MapValuesIterator#iterator for (self: MapValuesIterator[Object, nullable Object]): MapIterator[Object, nullable Object] */
2062 val
* abstract_collection__MapValuesIterator__iterator(val
* self
) {
2063 val
* var
/* : MapIterator[Object, nullable Object] */;
2064 val
* var1
/* : MapIterator[Object, nullable Object] */;
2065 var1
= self
->attrs
[COLOR_abstract_collection__MapValuesIterator___64diterator
].val
; /* @iterator on <self:MapValuesIterator[Object, nullable Object]> */
2067 fprintf(stderr
, "Runtime error: %s", "Uninitialized attribute @iterator");
2068 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 395);
2075 /* method abstract_collection#MapValuesIterator#iterator for (self: Object): MapIterator[Object, nullable Object] */
2076 val
* VIRTUAL_abstract_collection__MapValuesIterator__iterator(val
* self
) {
2077 val
* var
/* : MapIterator[Object, nullable Object] */;
2078 val
* var1
/* : MapIterator[Object, nullable Object] */;
2079 var1
= abstract_collection__MapValuesIterator__iterator(self
);
2084 /* method abstract_collection#MapValuesIterator#iterator= for (self: MapValuesIterator[Object, nullable Object], MapIterator[Object, nullable Object]) */
2085 void abstract_collection__MapValuesIterator__iterator_61d(val
* self
, val
* p0
) {
2086 short int var
/* : Bool */;
2089 const struct type
* type_struct
;
2090 const char* var_class_name
;
2091 /* Covariant cast for argument 0 (iterator) <p0:MapIterator[Object, nullable Object]> isa MapIterator[MapValuesIterator#0, MapValuesIterator#1] */
2092 /* <p0:MapIterator[Object, nullable Object]> isa MapIterator[MapValuesIterator#0, MapValuesIterator#1] */
2093 type_struct
= self
->type
->resolution_table
->types
[COLOR_abstract_collection__MapIteratorabstract_collection__MapValuesIterator_FT0abstract_collection__MapValuesIterator_FT1
];
2094 cltype
= type_struct
->color
;
2095 idtype
= type_struct
->id
;
2096 if(cltype
>= p0
->type
->table_size
) {
2099 var
= p0
->type
->type_table
[cltype
] == idtype
;
2102 var_class_name
= p0
== NULL ?
"null" : p0
->type
->name
;
2103 fprintf(stderr
, "Runtime error: Cast failed. Expected `%s`, got `%s`", "MapIterator[MapValuesIterator#0, MapValuesIterator#1]", var_class_name
);
2104 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 395);
2107 self
->attrs
[COLOR_abstract_collection__MapValuesIterator___64diterator
].val
= p0
; /* @iterator on <self:MapValuesIterator[Object, nullable Object]> */
2110 /* method abstract_collection#MapValuesIterator#iterator= for (self: Object, MapIterator[Object, nullable Object]) */
2111 void VIRTUAL_abstract_collection__MapValuesIterator__iterator_61d(val
* self
, val
* p0
) {
2112 abstract_collection__MapValuesIterator__iterator_61d(self
, p0
);
2115 /* method abstract_collection#MapValuesIterator#is_ok for (self: MapValuesIterator[Object, nullable Object]): Bool */
2116 short int abstract_collection__MapValuesIterator__is_ok(val
* self
) {
2117 short int var
/* : Bool */;
2118 val
* var1
/* : MapIterator[Object, nullable Object] */;
2119 short int var2
/* : Bool */;
2120 var1
= ((val
* (*)(val
*))(self
->class->vft
[COLOR_abstract_collection__MapValuesIterator__iterator
]))(self
) /* iterator on <self:MapValuesIterator[Object, nullable Object]>*/;
2121 var2
= ((short int (*)(val
*))(var1
->class->vft
[COLOR_abstract_collection__MapIterator__is_ok
]))(var1
) /* is_ok on <var1:MapIterator[Object, nullable Object]>*/;
2127 /* method abstract_collection#MapValuesIterator#is_ok for (self: Object): Bool */
2128 short int VIRTUAL_abstract_collection__MapValuesIterator__is_ok(val
* self
) {
2129 short int var
/* : Bool */;
2130 short int var1
/* : Bool */;
2131 var1
= abstract_collection__MapValuesIterator__is_ok(self
);
2136 /* method abstract_collection#MapValuesIterator#next for (self: MapValuesIterator[Object, nullable Object]) */
2137 void abstract_collection__MapValuesIterator__next(val
* self
) {
2138 val
* var
/* : MapIterator[Object, nullable Object] */;
2139 var
= ((val
* (*)(val
*))(self
->class->vft
[COLOR_abstract_collection__MapValuesIterator__iterator
]))(self
) /* iterator on <self:MapValuesIterator[Object, nullable Object]>*/;
2140 ((void (*)(val
*))(var
->class->vft
[COLOR_abstract_collection__MapIterator__next
]))(var
) /* next on <var:MapIterator[Object, nullable Object]>*/;
2143 /* method abstract_collection#MapValuesIterator#next for (self: Object) */
2144 void VIRTUAL_abstract_collection__MapValuesIterator__next(val
* self
) {
2145 abstract_collection__MapValuesIterator__next(self
);
2148 /* method abstract_collection#MapValuesIterator#item for (self: MapValuesIterator[Object, nullable Object]): nullable Object */
2149 val
* abstract_collection__MapValuesIterator__item(val
* self
) {
2150 val
* var
/* : nullable Object */;
2151 val
* var1
/* : MapIterator[Object, nullable Object] */;
2152 val
* var2
/* : nullable Object */;
2153 var1
= ((val
* (*)(val
*))(self
->class->vft
[COLOR_abstract_collection__MapValuesIterator__iterator
]))(self
) /* iterator on <self:MapValuesIterator[Object, nullable Object]>*/;
2154 var2
= ((val
* (*)(val
*))(var1
->class->vft
[COLOR_abstract_collection__MapIterator__item
]))(var1
) /* item on <var1:MapIterator[Object, nullable Object]>*/;
2160 /* method abstract_collection#MapValuesIterator#item for (self: Object): nullable Object */
2161 val
* VIRTUAL_abstract_collection__MapValuesIterator__item(val
* self
) {
2162 val
* var
/* : nullable Object */;
2163 val
* var1
/* : nullable Object */;
2164 var1
= abstract_collection__MapValuesIterator__item(self
);
2169 /* method abstract_collection#MapValuesIterator#init for (self: MapValuesIterator[Object, nullable Object], MapIterator[Object, nullable Object]) */
2170 void abstract_collection__MapValuesIterator__init(val
* self
, val
* p0
) {
2171 short int var
/* : Bool */;
2174 const struct type
* type_struct
;
2175 const char* var_class_name
;
2176 /* Covariant cast for argument 0 (iterator) <p0:MapIterator[Object, nullable Object]> isa MapIterator[MapValuesIterator#0, MapValuesIterator#1] */
2177 /* <p0:MapIterator[Object, nullable Object]> isa MapIterator[MapValuesIterator#0, MapValuesIterator#1] */
2178 type_struct
= self
->type
->resolution_table
->types
[COLOR_abstract_collection__MapIteratorabstract_collection__MapValuesIterator_FT0abstract_collection__MapValuesIterator_FT1
];
2179 cltype
= type_struct
->color
;
2180 idtype
= type_struct
->id
;
2181 if(cltype
>= p0
->type
->table_size
) {
2184 var
= p0
->type
->type_table
[cltype
] == idtype
;
2187 var_class_name
= p0
== NULL ?
"null" : p0
->type
->name
;
2188 fprintf(stderr
, "Runtime error: Cast failed. Expected `%s`, got `%s`", "MapIterator[MapValuesIterator#0, MapValuesIterator#1]", var_class_name
);
2189 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 392);
2192 self
->attrs
[COLOR_abstract_collection__MapValuesIterator___64diterator
].val
= p0
; /* @iterator on <self:MapValuesIterator[Object, nullable Object]> */
2195 /* method abstract_collection#MapValuesIterator#init for (self: Object, MapIterator[Object, nullable Object]) */
2196 void VIRTUAL_abstract_collection__MapValuesIterator__init(val
* self
, val
* p0
) {
2197 abstract_collection__MapValuesIterator__init(self
, p0
);
2200 /* method abstract_collection#SequenceRead#first for (self: SequenceRead[nullable Object]): nullable Object */
2201 val
* abstract_collection__SequenceRead__first(val
* self
) {
2202 val
* var
/* : nullable Object */;
2203 short int var1
/* : Bool */;
2204 short int var2
/* : Bool */;
2205 long var3
/* : Int */;
2206 val
* var4
/* : nullable Object */;
2207 var1
= ((short int (*)(val
*))(self
->class->vft
[COLOR_abstract_collection__Collection__is_empty
]))(self
) /* is_empty on <self:SequenceRead[nullable Object]>*/;
2210 fprintf(stderr
, "Runtime error: %s", "Assert \'not_empty\' failed");
2211 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 411);
2215 var4
= ((val
* (*)(val
*, long))(self
->class->vft
[COLOR_abstract_collection__SequenceRead___91d_93d
]))(self
, var3
) /* [] on <self:SequenceRead[nullable Object]>*/;
2221 /* method abstract_collection#SequenceRead#first for (self: Object): nullable Object */
2222 val
* VIRTUAL_abstract_collection__SequenceRead__first(val
* self
) {
2223 val
* var
/* : nullable Object */;
2224 val
* var1
/* : nullable Object */;
2225 var1
= abstract_collection__SequenceRead__first(self
);
2230 /* method abstract_collection#SequenceRead#[] for (self: SequenceRead[nullable Object], Int): nullable Object */
2231 val
* abstract_collection__SequenceRead___91d_93d(val
* self
, long p0
) {
2232 val
* var
/* : nullable Object */;
2233 const char* var_class_name
;
2234 var_class_name
= self
== NULL ?
"null" : self
->type
->name
;
2235 fprintf(stderr
, "Runtime error: Abstract method `%s` called on `%s`", "[]", var_class_name
);
2236 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 415);
2241 /* method abstract_collection#SequenceRead#[] for (self: Object, Int): nullable Object */
2242 val
* VIRTUAL_abstract_collection__SequenceRead___91d_93d(val
* self
, long p0
) {
2243 val
* var
/* : nullable Object */;
2244 val
* var1
/* : nullable Object */;
2245 var1
= abstract_collection__SequenceRead___91d_93d(self
, p0
);
2250 /* method abstract_collection#SequenceRead#last for (self: SequenceRead[nullable Object]): nullable Object */
2251 val
* abstract_collection__SequenceRead__last(val
* self
) {
2252 val
* var
/* : nullable Object */;
2253 short int var1
/* : Bool */;
2254 short int var2
/* : Bool */;
2255 long var3
/* : Int */;
2256 long var4
/* : Int */;
2257 long var5
/* : Int */;
2258 long var7
/* : Int */;
2259 val
* var8
/* : nullable Object */;
2260 var1
= ((short int (*)(val
*))(self
->class->vft
[COLOR_abstract_collection__Collection__is_empty
]))(self
) /* is_empty on <self:SequenceRead[nullable Object]>*/;
2263 fprintf(stderr
, "Runtime error: %s", "Assert \'not_empty\' failed");
2264 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 424);
2267 var3
= ((long (*)(val
*))(self
->class->vft
[COLOR_abstract_collection__Collection__length
]))(self
) /* length on <self:SequenceRead[nullable Object]>*/;
2269 { /* Inline kernel#Int#- (var3,var4) */
2275 var8
= ((val
* (*)(val
*, long))(self
->class->vft
[COLOR_abstract_collection__SequenceRead___91d_93d
]))(self
, var5
) /* [] on <self:SequenceRead[nullable Object]>*/;
2281 /* method abstract_collection#SequenceRead#last for (self: Object): nullable Object */
2282 val
* VIRTUAL_abstract_collection__SequenceRead__last(val
* self
) {
2283 val
* var
/* : nullable Object */;
2284 val
* var1
/* : nullable Object */;
2285 var1
= abstract_collection__SequenceRead__last(self
);
2290 /* method abstract_collection#SequenceRead#index_of for (self: SequenceRead[nullable Object], nullable Object): Int */
2291 long abstract_collection__SequenceRead__index_of(val
* self
, val
* p0
) {
2292 long var
/* : Int */;
2293 short int var1
/* : Bool */;
2296 const struct type
* type_struct
;
2297 short int is_nullable
;
2298 const char* var_class_name
;
2299 val
* var_item
/* var item: nullable Object */;
2300 val
* var2
/* : Iterator[nullable Object] */;
2301 val
* var_i
/* var i: IndexedIterator[nullable Object] */;
2302 short int var3
/* : Bool */;
2303 val
* var4
/* : nullable Object */;
2304 short int var5
/* : Bool */;
2305 long var6
/* : Int */;
2306 long var7
/* : Int */;
2307 long var8
/* : Int */;
2308 long var10
/* : Int */;
2309 /* Covariant cast for argument 0 (item) <p0:nullable Object> isa SequenceRead#0 */
2310 /* <p0:nullable Object> isa SequenceRead#0 */
2311 type_struct
= self
->type
->resolution_table
->types
[COLOR_abstract_collection__SequenceRead_FT0
];
2312 cltype
= type_struct
->color
;
2313 idtype
= type_struct
->id
;
2314 is_nullable
= type_struct
->is_nullable
;
2318 if(cltype
>= p0
->type
->table_size
) {
2321 var1
= p0
->type
->type_table
[cltype
] == idtype
;
2325 var_class_name
= p0
== NULL ?
"null" : p0
->type
->name
;
2326 fprintf(stderr
, "Runtime error: Cast failed. Expected `%s`, got `%s`", "SequenceRead#0", var_class_name
);
2327 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 428);
2331 var2
= ((val
* (*)(val
*))(self
->class->vft
[COLOR_abstract_collection__Collection__iterator
]))(self
) /* iterator on <self:SequenceRead[nullable Object]>*/;
2334 var3
= ((short int (*)(val
*))(var_i
->class->vft
[COLOR_abstract_collection__Iterator__is_ok
]))(var_i
) /* is_ok on <var_i:IndexedIterator[nullable Object]>*/;
2336 var4
= ((val
* (*)(val
*))(var_i
->class->vft
[COLOR_abstract_collection__Iterator__item
]))(var_i
) /* item on <var_i:IndexedIterator[nullable Object]>*/;
2338 var5
= (var_item
== NULL
);
2340 var5
= ((short int (*)(val
*, val
*))(var4
->class->vft
[COLOR_kernel__Object___61d_61d
]))(var4
, var_item
) /* == on <var4:nullable Object>*/;
2343 var6
= ((long (*)(val
*))(var_i
->class->vft
[COLOR_abstract_collection__IndexedIterator__index
]))(var_i
) /* index on <var_i:IndexedIterator[nullable Object]>*/;
2348 ((void (*)(val
*))(var_i
->class->vft
[COLOR_abstract_collection__Iterator__next
]))(var_i
) /* next on <var_i:IndexedIterator[nullable Object]>*/;
2349 CONTINUE_label
: (void)0;
2351 BREAK_label
: (void)0;
2353 { /* Inline kernel#Int#unary - (var7) */
2364 /* method abstract_collection#SequenceRead#index_of for (self: Object, nullable Object): Int */
2365 long VIRTUAL_abstract_collection__SequenceRead__index_of(val
* self
, val
* p0
) {
2366 long var
/* : Int */;
2367 long var1
/* : Int */;
2368 var1
= abstract_collection__SequenceRead__index_of(self
, p0
);
2373 /* method abstract_collection#SequenceRead#iterator for (self: SequenceRead[nullable Object]): IndexedIterator[nullable Object] */
2374 val
* abstract_collection__SequenceRead__iterator(val
* self
) {
2375 val
* var
/* : IndexedIterator[nullable Object] */;
2376 const char* var_class_name
;
2377 var_class_name
= self
== NULL ?
"null" : self
->type
->name
;
2378 fprintf(stderr
, "Runtime error: Abstract method `%s` called on `%s`", "iterator", var_class_name
);
2379 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 441);
2384 /* method abstract_collection#SequenceRead#iterator for (self: Object): Iterator[nullable Object] */
2385 val
* VIRTUAL_abstract_collection__SequenceRead__iterator(val
* self
) {
2386 val
* var
/* : Iterator[nullable Object] */;
2387 val
* var1
/* : IndexedIterator[nullable Object] */;
2388 var1
= abstract_collection__SequenceRead__iterator(self
);
2393 /* method abstract_collection#SequenceRead#== for (self: SequenceRead[nullable Object], nullable Object): Bool */
2394 short int abstract_collection__SequenceRead___61d_61d(val
* self
, val
* p0
) {
2395 short int var
/* : Bool */;
2396 val
* var_o
/* var o: nullable Object */;
2397 short int var1
/* : Bool */;
2400 short int var2
/* : Bool */;
2401 short int var3
/* : Bool */;
2402 long var4
/* : Int */;
2403 long var_l
/* var l: Int */;
2404 long var5
/* : Int */;
2405 short int var6
/* : Bool */;
2406 short int var8
/* : Bool */;
2407 short int var9
/* : Bool */;
2408 short int var10
/* : Bool */;
2409 long var11
/* : Int */;
2410 long var_i
/* var i: Int */;
2411 short int var12
/* : Bool */;
2412 short int var14
/* : Bool */;
2415 const char* var_class_name
;
2416 short int var17
/* : Bool */;
2417 val
* var18
/* : nullable Object */;
2418 val
* var19
/* : nullable Object */;
2419 short int var20
/* : Bool */;
2420 short int var21
/* : Bool */;
2421 long var22
/* : Int */;
2422 long var23
/* : Int */;
2423 long var25
/* : Int */;
2424 short int var26
/* : Bool */;
2426 /* <var_o:nullable Object> isa SequenceRead[nullable Object] */
2427 cltype
= type_abstract_collection__SequenceReadnullable_kernel__Object
.color
;
2428 idtype
= type_abstract_collection__SequenceReadnullable_kernel__Object
.id
;
2432 if(cltype
>= var_o
->type
->table_size
) {
2435 var1
= var_o
->type
->type_table
[cltype
] == idtype
;
2445 var4
= ((long (*)(val
*))(self
->class->vft
[COLOR_abstract_collection__Collection__length
]))(self
) /* length on <self:SequenceRead[nullable Object]>*/;
2447 var5
= ((long (*)(val
*))(var_o
->class->vft
[COLOR_abstract_collection__Collection__length
]))(var_o
) /* length on <var_o:nullable Object(SequenceRead[nullable Object])>*/;
2448 { /* Inline kernel#Int#!= (var5,var_l) */
2449 var8
= var5
== var_l
;
2464 { /* Inline kernel#Int#< (var_i,var_l) */
2465 /* Covariant cast for argument 0 (i) <var_l:Int> isa OTHER */
2466 /* <var_l:Int> isa OTHER */
2467 var14
= 1; /* easy <var_l:Int> isa OTHER*/
2469 var_class_name
= type_kernel__Int
.name
;
2470 fprintf(stderr
, "Runtime error: Cast failed. Expected `%s`, got `%s`", "OTHER", var_class_name
);
2471 fprintf(stderr
, " (%s:%d)\n", "lib/standard/kernel.nit", 261);
2474 var17
= var_i
< var_l
;
2477 RET_LABEL13
:(void)0;
2480 var18
= ((val
* (*)(val
*, long))(self
->class->vft
[COLOR_abstract_collection__SequenceRead___91d_93d
]))(self
, var_i
) /* [] on <self:SequenceRead[nullable Object]>*/;
2481 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])>*/;
2482 if (var18
== NULL
) {
2483 var20
= (var19
!= NULL
);
2485 var20
= ((short int (*)(val
*, val
*))(var18
->class->vft
[COLOR_kernel__Object___33d_61d
]))(var18
, var19
) /* != on <var18:nullable Object>*/;
2494 { /* Inline kernel#Int#+ (var_i,var22) */
2495 var25
= var_i
+ var22
;
2498 RET_LABEL24
:(void)0;
2501 CONTINUE_label
: (void)0;
2503 BREAK_label
: (void)0;
2510 /* method abstract_collection#SequenceRead#== for (self: Object, nullable Object): Bool */
2511 short int VIRTUAL_abstract_collection__SequenceRead___61d_61d(val
* self
, val
* p0
) {
2512 short int var
/* : Bool */;
2513 short int var1
/* : Bool */;
2514 var1
= abstract_collection__SequenceRead___61d_61d(self
, p0
);
2519 /* method abstract_collection#SequenceRead#hash for (self: SequenceRead[nullable Object]): Int */
2520 long abstract_collection__SequenceRead__hash(val
* self
) {
2521 long var
/* : Int */;
2522 long var1
/* : Int */;
2523 long var_res
/* var res: Int */;
2524 val
* var2
/* : Iterator[nullable Object] */;
2525 short int var3
/* : Bool */;
2526 val
* var4
/* : nullable Object */;
2527 val
* var_e
/* var e: nullable Object */;
2528 long var5
/* : Int */;
2529 long var6
/* : Int */;
2530 long var8
/* : Int */;
2533 var2
= ((val
* (*)(val
*))(self
->class->vft
[COLOR_abstract_collection__Collection__iterator
]))(self
) /* iterator on <self:SequenceRead[nullable Object]>*/;
2535 var3
= ((short int (*)(val
*))(var2
->class->vft
[COLOR_abstract_collection__Iterator__is_ok
]))(var2
) /* is_ok on <var2:Iterator[nullable Object]>*/;
2537 var4
= ((val
* (*)(val
*))(var2
->class->vft
[COLOR_abstract_collection__Iterator__item
]))(var2
) /* item on <var2:Iterator[nullable Object]>*/;
2539 var5
= kernel__Int__hash(var_res
);
2540 { /* Inline kernel#Int#+ (var_res,var5) */
2541 var8
= var_res
+ var5
;
2547 CONTINUE_label
: (void)0;
2548 ((void (*)(val
*))(var2
->class->vft
[COLOR_abstract_collection__Iterator__next
]))(var2
) /* next on <var2:Iterator[nullable Object]>*/;
2550 BREAK_label
: (void)0;
2556 /* method abstract_collection#SequenceRead#hash for (self: Object): Int */
2557 long VIRTUAL_abstract_collection__SequenceRead__hash(val
* self
) {
2558 long var
/* : Int */;
2559 long var1
/* : Int */;
2560 var1
= abstract_collection__SequenceRead__hash(self
);
2565 /* method abstract_collection#Sequence#first= for (self: Sequence[nullable Object], nullable Object) */
2566 void abstract_collection__Sequence__first_61d(val
* self
, val
* p0
) {
2567 short int var
/* : Bool */;
2570 const struct type
* type_struct
;
2571 short int is_nullable
;
2572 const char* var_class_name
;
2573 val
* var_item
/* var item: nullable Object */;
2574 long var1
/* : Int */;
2575 /* Covariant cast for argument 0 (item) <p0:nullable Object> isa Sequence#0 */
2576 /* <p0:nullable Object> isa Sequence#0 */
2577 type_struct
= self
->type
->resolution_table
->types
[COLOR_abstract_collection__Sequence_FT0
];
2578 cltype
= type_struct
->color
;
2579 idtype
= type_struct
->id
;
2580 is_nullable
= type_struct
->is_nullable
;
2584 if(cltype
>= p0
->type
->table_size
) {
2587 var
= p0
->type
->type_table
[cltype
] == idtype
;
2591 var_class_name
= p0
== NULL ?
"null" : p0
->type
->name
;
2592 fprintf(stderr
, "Runtime error: Cast failed. Expected `%s`, got `%s`", "Sequence#0", var_class_name
);
2593 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 472);
2598 ((void (*)(val
*, long, val
*))(self
->class->vft
[COLOR_abstract_collection__Sequence___91d_93d_61d
]))(self
, var1
, var_item
) /* []= on <self:Sequence[nullable Object]>*/;
2601 /* method abstract_collection#Sequence#first= for (self: Object, nullable Object) */
2602 void VIRTUAL_abstract_collection__Sequence__first_61d(val
* self
, val
* p0
) {
2603 abstract_collection__Sequence__first_61d(self
, p0
);
2606 /* method abstract_collection#Sequence#last= for (self: Sequence[nullable Object], nullable Object) */
2607 void abstract_collection__Sequence__last_61d(val
* self
, val
* p0
) {
2608 short int var
/* : Bool */;
2611 const struct type
* type_struct
;
2612 short int is_nullable
;
2613 const char* var_class_name
;
2614 val
* var_item
/* var item: nullable Object */;
2615 long var1
/* : Int */;
2616 long var_l
/* var l: Int */;
2617 long var2
/* : Int */;
2618 short int var3
/* : Bool */;
2619 short int var5
/* : Bool */;
2622 const char* var_class_name8
;
2623 short int var9
/* : Bool */;
2624 long var10
/* : Int */;
2625 long var11
/* : Int */;
2626 long var13
/* : Int */;
2627 long var14
/* : Int */;
2628 /* Covariant cast for argument 0 (item) <p0:nullable Object> isa Sequence#0 */
2629 /* <p0:nullable Object> isa Sequence#0 */
2630 type_struct
= self
->type
->resolution_table
->types
[COLOR_abstract_collection__Sequence_FT0
];
2631 cltype
= type_struct
->color
;
2632 idtype
= type_struct
->id
;
2633 is_nullable
= type_struct
->is_nullable
;
2637 if(cltype
>= p0
->type
->table_size
) {
2640 var
= p0
->type
->type_table
[cltype
] == idtype
;
2644 var_class_name
= p0
== NULL ?
"null" : p0
->type
->name
;
2645 fprintf(stderr
, "Runtime error: Cast failed. Expected `%s`, got `%s`", "Sequence#0", var_class_name
);
2646 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 477);
2650 var1
= ((long (*)(val
*))(self
->class->vft
[COLOR_abstract_collection__Collection__length
]))(self
) /* length on <self:Sequence[nullable Object]>*/;
2653 { /* Inline kernel#Int#> (var_l,var2) */
2654 /* Covariant cast for argument 0 (i) <var2:Int> isa OTHER */
2655 /* <var2:Int> isa OTHER */
2656 var5
= 1; /* easy <var2:Int> isa OTHER*/
2658 var_class_name8
= type_kernel__Int
.name
;
2659 fprintf(stderr
, "Runtime error: Cast failed. Expected `%s`, got `%s`", "OTHER", var_class_name8
);
2660 fprintf(stderr
, " (%s:%d)\n", "lib/standard/kernel.nit", 263);
2663 var9
= var_l
> var2
;
2670 { /* Inline kernel#Int#- (var_l,var10) */
2671 var13
= var_l
- var10
;
2674 RET_LABEL12
:(void)0;
2676 ((void (*)(val
*, long, val
*))(self
->class->vft
[COLOR_abstract_collection__Sequence___91d_93d_61d
]))(self
, var11
, var_item
) /* []= on <self:Sequence[nullable Object]>*/;
2679 ((void (*)(val
*, long, val
*))(self
->class->vft
[COLOR_abstract_collection__Sequence___91d_93d_61d
]))(self
, var14
, var_item
) /* []= on <self:Sequence[nullable Object]>*/;
2683 /* method abstract_collection#Sequence#last= for (self: Object, nullable Object) */
2684 void VIRTUAL_abstract_collection__Sequence__last_61d(val
* self
, val
* p0
) {
2685 abstract_collection__Sequence__last_61d(self
, p0
);
2688 /* method abstract_collection#Sequence#add for (self: Sequence[nullable Object], nullable Object) */
2689 void abstract_collection__Sequence__add(val
* self
, val
* p0
) {
2690 short int var
/* : Bool */;
2693 const struct type
* type_struct
;
2694 short int is_nullable
;
2695 const char* var_class_name
;
2696 val
* var_e
/* var e: nullable Object */;
2697 /* Covariant cast for argument 0 (e) <p0:nullable Object> isa SimpleCollection#0 */
2698 /* <p0:nullable Object> isa SimpleCollection#0 */
2699 type_struct
= self
->type
->resolution_table
->types
[COLOR_abstract_collection__SimpleCollection_FT0
];
2700 cltype
= type_struct
->color
;
2701 idtype
= type_struct
->id
;
2702 is_nullable
= type_struct
->is_nullable
;
2706 if(cltype
>= p0
->type
->table_size
) {
2709 var
= p0
->type
->type_table
[cltype
] == idtype
;
2713 var_class_name
= p0
== NULL ?
"null" : p0
->type
->name
;
2714 fprintf(stderr
, "Runtime error: Cast failed. Expected `%s`, got `%s`", "SimpleCollection#0", var_class_name
);
2715 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 489);
2719 ((void (*)(val
*, val
*))(self
->class->vft
[COLOR_abstract_collection__Sequence__push
]))(self
, var_e
) /* push on <self:Sequence[nullable Object]>*/;
2722 /* method abstract_collection#Sequence#add for (self: Object, nullable Object) */
2723 void VIRTUAL_abstract_collection__Sequence__add(val
* self
, val
* p0
) {
2724 abstract_collection__Sequence__add(self
, p0
);
2727 /* method abstract_collection#Sequence#push for (self: Sequence[nullable Object], nullable Object) */
2728 void abstract_collection__Sequence__push(val
* self
, val
* p0
) {
2729 short int var
/* : Bool */;
2732 const struct type
* type_struct
;
2733 short int is_nullable
;
2734 const char* var_class_name
;
2735 const char* var_class_name1
;
2736 /* Covariant cast for argument 0 (e) <p0:nullable Object> isa Sequence#0 */
2737 /* <p0:nullable Object> isa Sequence#0 */
2738 type_struct
= self
->type
->resolution_table
->types
[COLOR_abstract_collection__Sequence_FT0
];
2739 cltype
= type_struct
->color
;
2740 idtype
= type_struct
->id
;
2741 is_nullable
= type_struct
->is_nullable
;
2745 if(cltype
>= p0
->type
->table_size
) {
2748 var
= p0
->type
->type_table
[cltype
] == idtype
;
2752 var_class_name
= p0
== NULL ?
"null" : p0
->type
->name
;
2753 fprintf(stderr
, "Runtime error: Cast failed. Expected `%s`, got `%s`", "Sequence#0", var_class_name
);
2754 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 492);
2757 var_class_name1
= self
== NULL ?
"null" : self
->type
->name
;
2758 fprintf(stderr
, "Runtime error: Abstract method `%s` called on `%s`", "push", var_class_name1
);
2759 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 492);
2763 /* method abstract_collection#Sequence#push for (self: Object, nullable Object) */
2764 void VIRTUAL_abstract_collection__Sequence__push(val
* self
, val
* p0
) {
2765 abstract_collection__Sequence__push(self
, p0
);
2768 /* method abstract_collection#Sequence#append for (self: Sequence[nullable Object], Collection[nullable Object]) */
2769 void abstract_collection__Sequence__append(val
* self
, val
* p0
) {
2770 short int var
/* : Bool */;
2773 const struct type
* type_struct
;
2774 const char* var_class_name
;
2775 val
* var_coll
/* var coll: Collection[nullable Object] */;
2776 val
* var1
/* : Iterator[nullable Object] */;
2777 short int var2
/* : Bool */;
2778 val
* var3
/* : nullable Object */;
2779 val
* var_i
/* var i: nullable Object */;
2780 /* Covariant cast for argument 0 (coll) <p0:Collection[nullable Object]> isa Collection[Sequence#0] */
2781 /* <p0:Collection[nullable Object]> isa Collection[Sequence#0] */
2782 type_struct
= self
->type
->resolution_table
->types
[COLOR_abstract_collection__Collectionabstract_collection__Sequence_FT0
];
2783 cltype
= type_struct
->color
;
2784 idtype
= type_struct
->id
;
2785 if(cltype
>= p0
->type
->table_size
) {
2788 var
= p0
->type
->type_table
[cltype
] == idtype
;
2791 var_class_name
= p0
== NULL ?
"null" : p0
->type
->name
;
2792 fprintf(stderr
, "Runtime error: Cast failed. Expected `%s`, got `%s`", "Collection[Sequence#0]", var_class_name
);
2793 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 495);
2797 var1
= ((val
* (*)(val
*))(var_coll
->class->vft
[COLOR_abstract_collection__Collection__iterator
]))(var_coll
) /* iterator on <var_coll:Collection[nullable Object]>*/;
2799 var2
= ((short int (*)(val
*))(var1
->class->vft
[COLOR_abstract_collection__Iterator__is_ok
]))(var1
) /* is_ok on <var1:Iterator[nullable Object]>*/;
2801 var3
= ((val
* (*)(val
*))(var1
->class->vft
[COLOR_abstract_collection__Iterator__item
]))(var1
) /* item on <var1:Iterator[nullable Object]>*/;
2803 ((void (*)(val
*, val
*))(self
->class->vft
[COLOR_abstract_collection__Sequence__push
]))(self
, var_i
) /* push on <self:Sequence[nullable Object]>*/;
2804 CONTINUE_label
: (void)0;
2805 ((void (*)(val
*))(var1
->class->vft
[COLOR_abstract_collection__Iterator__next
]))(var1
) /* next on <var1:Iterator[nullable Object]>*/;
2807 BREAK_label
: (void)0;
2810 /* method abstract_collection#Sequence#append for (self: Object, Collection[nullable Object]) */
2811 void VIRTUAL_abstract_collection__Sequence__append(val
* self
, val
* p0
) {
2812 abstract_collection__Sequence__append(self
, p0
);
2815 /* method abstract_collection#Sequence#pop for (self: Sequence[nullable Object]): nullable Object */
2816 val
* abstract_collection__Sequence__pop(val
* self
) {
2817 val
* var
/* : nullable Object */;
2818 const char* var_class_name
;
2819 var_class_name
= self
== NULL ?
"null" : self
->type
->name
;
2820 fprintf(stderr
, "Runtime error: Abstract method `%s` called on `%s`", "pop", var_class_name
);
2821 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 498);
2826 /* method abstract_collection#Sequence#pop for (self: Object): nullable Object */
2827 val
* VIRTUAL_abstract_collection__Sequence__pop(val
* self
) {
2828 val
* var
/* : nullable Object */;
2829 val
* var1
/* : nullable Object */;
2830 var1
= abstract_collection__Sequence__pop(self
);
2835 /* method abstract_collection#Sequence#unshift for (self: Sequence[nullable Object], nullable Object) */
2836 void abstract_collection__Sequence__unshift(val
* self
, val
* p0
) {
2837 short int var
/* : Bool */;
2840 const struct type
* type_struct
;
2841 short int is_nullable
;
2842 const char* var_class_name
;
2843 const char* var_class_name1
;
2844 /* Covariant cast for argument 0 (e) <p0:nullable Object> isa Sequence#0 */
2845 /* <p0:nullable Object> isa Sequence#0 */
2846 type_struct
= self
->type
->resolution_table
->types
[COLOR_abstract_collection__Sequence_FT0
];
2847 cltype
= type_struct
->color
;
2848 idtype
= type_struct
->id
;
2849 is_nullable
= type_struct
->is_nullable
;
2853 if(cltype
>= p0
->type
->table_size
) {
2856 var
= p0
->type
->type_table
[cltype
] == idtype
;
2860 var_class_name
= p0
== NULL ?
"null" : p0
->type
->name
;
2861 fprintf(stderr
, "Runtime error: Cast failed. Expected `%s`, got `%s`", "Sequence#0", var_class_name
);
2862 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 501);
2865 var_class_name1
= self
== NULL ?
"null" : self
->type
->name
;
2866 fprintf(stderr
, "Runtime error: Abstract method `%s` called on `%s`", "unshift", var_class_name1
);
2867 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 501);
2871 /* method abstract_collection#Sequence#unshift for (self: Object, nullable Object) */
2872 void VIRTUAL_abstract_collection__Sequence__unshift(val
* self
, val
* p0
) {
2873 abstract_collection__Sequence__unshift(self
, p0
);
2876 /* method abstract_collection#Sequence#shift for (self: Sequence[nullable Object]): nullable Object */
2877 val
* abstract_collection__Sequence__shift(val
* self
) {
2878 val
* var
/* : nullable Object */;
2879 const char* var_class_name
;
2880 var_class_name
= self
== NULL ?
"null" : self
->type
->name
;
2881 fprintf(stderr
, "Runtime error: Abstract method `%s` called on `%s`", "shift", var_class_name
);
2882 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 504);
2887 /* method abstract_collection#Sequence#shift for (self: Object): nullable Object */
2888 val
* VIRTUAL_abstract_collection__Sequence__shift(val
* self
) {
2889 val
* var
/* : nullable Object */;
2890 val
* var1
/* : nullable Object */;
2891 var1
= abstract_collection__Sequence__shift(self
);
2896 /* method abstract_collection#Sequence#[]= for (self: Sequence[nullable Object], Int, nullable Object) */
2897 void abstract_collection__Sequence___91d_93d_61d(val
* self
, long p0
, val
* p1
) {
2898 short int var
/* : Bool */;
2901 const struct type
* type_struct
;
2902 short int is_nullable
;
2903 const char* var_class_name
;
2904 const char* var_class_name1
;
2905 /* Covariant cast for argument 1 (item) <p1:nullable Object> isa Sequence#0 */
2906 /* <p1:nullable Object> isa Sequence#0 */
2907 type_struct
= self
->type
->resolution_table
->types
[COLOR_abstract_collection__Sequence_FT0
];
2908 cltype
= type_struct
->color
;
2909 idtype
= type_struct
->id
;
2910 is_nullable
= type_struct
->is_nullable
;
2914 if(cltype
>= p1
->type
->table_size
) {
2917 var
= p1
->type
->type_table
[cltype
] == idtype
;
2921 var_class_name
= p1
== NULL ?
"null" : p1
->type
->name
;
2922 fprintf(stderr
, "Runtime error: Cast failed. Expected `%s`, got `%s`", "Sequence#0", var_class_name
);
2923 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 508);
2926 var_class_name1
= self
== NULL ?
"null" : self
->type
->name
;
2927 fprintf(stderr
, "Runtime error: Abstract method `%s` called on `%s`", "[]=", var_class_name1
);
2928 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 508);
2932 /* method abstract_collection#Sequence#[]= for (self: Object, Int, nullable Object) */
2933 void VIRTUAL_abstract_collection__Sequence___91d_93d_61d(val
* self
, long p0
, val
* p1
) {
2934 abstract_collection__Sequence___91d_93d_61d(self
, p0
, p1
);
2937 /* method abstract_collection#Sequence#remove_at for (self: Sequence[nullable Object], Int) */
2938 void abstract_collection__Sequence__remove_at(val
* self
, long p0
) {
2939 const char* var_class_name
;
2940 var_class_name
= self
== NULL ?
"null" : self
->type
->name
;
2941 fprintf(stderr
, "Runtime error: Abstract method `%s` called on `%s`", "remove_at", var_class_name
);
2942 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 511);
2946 /* method abstract_collection#Sequence#remove_at for (self: Object, Int) */
2947 void VIRTUAL_abstract_collection__Sequence__remove_at(val
* self
, long p0
) {
2948 abstract_collection__Sequence__remove_at(self
, p0
);
2951 /* method abstract_collection#IndexedIterator#index for (self: IndexedIterator[nullable Object]): Int */
2952 long abstract_collection__IndexedIterator__index(val
* self
) {
2953 long var
/* : Int */;
2954 const char* var_class_name
;
2955 var_class_name
= self
== NULL ?
"null" : self
->type
->name
;
2956 fprintf(stderr
, "Runtime error: Abstract method `%s` called on `%s`", "index", var_class_name
);
2957 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 518);
2962 /* method abstract_collection#IndexedIterator#index for (self: Object): Int */
2963 long VIRTUAL_abstract_collection__IndexedIterator__index(val
* self
) {
2964 long var
/* : Int */;
2965 long var1
/* : Int */;
2966 var1
= abstract_collection__IndexedIterator__index(self
);
2971 /* method abstract_collection#CoupleMap#couple_at for (self: CoupleMap[Object, nullable Object], Object): nullable Couple[Object, nullable Object] */
2972 val
* abstract_collection__CoupleMap__couple_at(val
* self
, val
* p0
) {
2973 val
* var
/* : nullable Couple[Object, nullable Object] */;
2974 short int var1
/* : Bool */;
2977 const struct type
* type_struct
;
2978 const char* var_class_name
;
2979 const char* var_class_name2
;
2980 /* Covariant cast for argument 0 (key) <p0:Object> isa CoupleMap#0 */
2981 /* <p0:Object> isa CoupleMap#0 */
2982 type_struct
= self
->type
->resolution_table
->types
[COLOR_abstract_collection__CoupleMap_FT0
];
2983 cltype
= type_struct
->color
;
2984 idtype
= type_struct
->id
;
2985 if(cltype
>= p0
->type
->table_size
) {
2988 var1
= p0
->type
->type_table
[cltype
] == idtype
;
2991 var_class_name
= p0
== NULL ?
"null" : p0
->type
->name
;
2992 fprintf(stderr
, "Runtime error: Cast failed. Expected `%s`, got `%s`", "CoupleMap#0", var_class_name
);
2993 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 525);
2996 var_class_name2
= self
== NULL ?
"null" : self
->type
->name
;
2997 fprintf(stderr
, "Runtime error: Abstract method `%s` called on `%s`", "couple_at", var_class_name2
);
2998 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 525);
3003 /* method abstract_collection#CoupleMap#couple_at for (self: Object, Object): nullable Couple[Object, nullable Object] */
3004 val
* VIRTUAL_abstract_collection__CoupleMap__couple_at(val
* self
, val
* p0
) {
3005 val
* var
/* : nullable Couple[Object, nullable Object] */;
3006 val
* var1
/* : nullable Couple[Object, nullable Object] */;
3007 var1
= abstract_collection__CoupleMap__couple_at(self
, p0
);
3012 /* method abstract_collection#CoupleMap#[] for (self: CoupleMap[Object, nullable Object], Object): nullable Object */
3013 val
* abstract_collection__CoupleMap___91d_93d(val
* self
, val
* p0
) {
3014 val
* var
/* : nullable Object */;
3015 short int var1
/* : Bool */;
3018 const struct type
* type_struct
;
3019 const char* var_class_name
;
3020 val
* var_key
/* var key: Object */;
3021 val
* var2
/* : nullable Couple[Object, nullable Object] */;
3022 val
* var_c
/* var c: nullable Couple[Object, nullable Object] */;
3023 val
* var3
/* : null */;
3024 short int var4
/* : Bool */;
3025 val
* var5
/* : nullable Object */;
3026 /* Covariant cast for argument 0 (key) <p0:Object> isa MapRead#0 */
3027 /* <p0:Object> isa MapRead#0 */
3028 type_struct
= self
->type
->resolution_table
->types
[COLOR_abstract_collection__MapRead_FT0
];
3029 cltype
= type_struct
->color
;
3030 idtype
= type_struct
->id
;
3031 if(cltype
>= p0
->type
->table_size
) {
3034 var1
= p0
->type
->type_table
[cltype
] == idtype
;
3037 var_class_name
= p0
== NULL ?
"null" : p0
->type
->name
;
3038 fprintf(stderr
, "Runtime error: Cast failed. Expected `%s`, got `%s`", "MapRead#0", var_class_name
);
3039 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 529);
3043 var2
= ((val
* (*)(val
*, val
*))(self
->class->vft
[COLOR_abstract_collection__CoupleMap__couple_at
]))(self
, var_key
) /* couple_at on <self:CoupleMap[Object, nullable Object]>*/;
3046 if (var_c
== NULL
) {
3047 var4
= 1; /* is null */
3049 var4
= 0; /* arg is null but recv is not */
3052 fprintf(stderr
, "Runtime error: %s", "Aborted");
3053 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 533);
3056 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])>*/;
3063 /* method abstract_collection#CoupleMap#[] for (self: Object, Object): nullable Object */
3064 val
* VIRTUAL_abstract_collection__CoupleMap___91d_93d(val
* self
, val
* p0
) {
3065 val
* var
/* : nullable Object */;
3066 val
* var1
/* : nullable Object */;
3067 var1
= abstract_collection__CoupleMap___91d_93d(self
, p0
);
3072 /* method abstract_collection#CoupleMapIterator#item for (self: CoupleMapIterator[Object, nullable Object]): nullable Object */
3073 val
* abstract_collection__CoupleMapIterator__item(val
* self
) {
3074 val
* var
/* : nullable Object */;
3075 val
* var1
/* : Iterator[Couple[Object, nullable Object]] */;
3076 val
* var2
/* : nullable Object */;
3077 val
* var3
/* : nullable Object */;
3078 var1
= self
->attrs
[COLOR_abstract_collection__CoupleMapIterator___iter
].val
; /* _iter on <self:CoupleMapIterator[Object, nullable Object]> */
3080 fprintf(stderr
, "Runtime error: %s", "Uninitialized attribute _iter");
3081 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 545);
3084 var2
= ((val
* (*)(val
*))(var1
->class->vft
[COLOR_abstract_collection__Iterator__item
]))(var1
) /* item on <var1:Iterator[Couple[Object, nullable Object]]>*/;
3085 var3
= ((val
* (*)(val
*))(var2
->class->vft
[COLOR_abstract_collection__Couple__second
]))(var2
) /* second on <var2:nullable Object(Couple[Object, nullable Object])>*/;
3091 /* method abstract_collection#CoupleMapIterator#item for (self: Object): nullable Object */
3092 val
* VIRTUAL_abstract_collection__CoupleMapIterator__item(val
* self
) {
3093 val
* var
/* : nullable Object */;
3094 val
* var1
/* : nullable Object */;
3095 var1
= abstract_collection__CoupleMapIterator__item(self
);
3100 /* method abstract_collection#CoupleMapIterator#key for (self: CoupleMapIterator[Object, nullable Object]): Object */
3101 val
* abstract_collection__CoupleMapIterator__key(val
* self
) {
3102 val
* var
/* : Object */;
3103 val
* var1
/* : Iterator[Couple[Object, nullable Object]] */;
3104 val
* var2
/* : nullable Object */;
3105 val
* var3
/* : nullable Object */;
3106 var1
= self
->attrs
[COLOR_abstract_collection__CoupleMapIterator___iter
].val
; /* _iter on <self:CoupleMapIterator[Object, nullable Object]> */
3108 fprintf(stderr
, "Runtime error: %s", "Uninitialized attribute _iter");
3109 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 549);
3112 var2
= ((val
* (*)(val
*))(var1
->class->vft
[COLOR_abstract_collection__Iterator__item
]))(var1
) /* item on <var1:Iterator[Couple[Object, nullable Object]]>*/;
3113 var3
= ((val
* (*)(val
*))(var2
->class->vft
[COLOR_abstract_collection__Couple__first
]))(var2
) /* first on <var2:nullable Object(Couple[Object, nullable Object])>*/;
3119 /* method abstract_collection#CoupleMapIterator#key for (self: Object): Object */
3120 val
* VIRTUAL_abstract_collection__CoupleMapIterator__key(val
* self
) {
3121 val
* var
/* : Object */;
3122 val
* var1
/* : Object */;
3123 var1
= abstract_collection__CoupleMapIterator__key(self
);
3128 /* method abstract_collection#CoupleMapIterator#is_ok for (self: CoupleMapIterator[Object, nullable Object]): Bool */
3129 short int abstract_collection__CoupleMapIterator__is_ok(val
* self
) {
3130 short int var
/* : Bool */;
3131 val
* var1
/* : Iterator[Couple[Object, nullable Object]] */;
3132 short int var2
/* : Bool */;
3133 var1
= self
->attrs
[COLOR_abstract_collection__CoupleMapIterator___iter
].val
; /* _iter on <self:CoupleMapIterator[Object, nullable Object]> */
3135 fprintf(stderr
, "Runtime error: %s", "Uninitialized attribute _iter");
3136 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 551);
3139 var2
= ((short int (*)(val
*))(var1
->class->vft
[COLOR_abstract_collection__Iterator__is_ok
]))(var1
) /* is_ok on <var1:Iterator[Couple[Object, nullable Object]]>*/;
3145 /* method abstract_collection#CoupleMapIterator#is_ok for (self: Object): Bool */
3146 short int VIRTUAL_abstract_collection__CoupleMapIterator__is_ok(val
* self
) {
3147 short int var
/* : Bool */;
3148 short int var1
/* : Bool */;
3149 var1
= abstract_collection__CoupleMapIterator__is_ok(self
);
3154 /* method abstract_collection#CoupleMapIterator#next for (self: CoupleMapIterator[Object, nullable Object]) */
3155 void abstract_collection__CoupleMapIterator__next(val
* self
) {
3156 val
* var
/* : Iterator[Couple[Object, nullable Object]] */;
3157 var
= self
->attrs
[COLOR_abstract_collection__CoupleMapIterator___iter
].val
; /* _iter on <self:CoupleMapIterator[Object, nullable Object]> */
3159 fprintf(stderr
, "Runtime error: %s", "Uninitialized attribute _iter");
3160 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 555);
3163 ((void (*)(val
*))(var
->class->vft
[COLOR_abstract_collection__Iterator__next
]))(var
) /* next on <var:Iterator[Couple[Object, nullable Object]]>*/;
3166 /* method abstract_collection#CoupleMapIterator#next for (self: Object) */
3167 void VIRTUAL_abstract_collection__CoupleMapIterator__next(val
* self
) {
3168 abstract_collection__CoupleMapIterator__next(self
);
3171 /* method abstract_collection#CoupleMapIterator#init for (self: CoupleMapIterator[Object, nullable Object], Iterator[Couple[Object, nullable Object]]) */
3172 void abstract_collection__CoupleMapIterator__init(val
* self
, val
* p0
) {
3173 short int var
/* : Bool */;
3176 const struct type
* type_struct
;
3177 const char* var_class_name
;
3178 val
* var_i
/* var i: Iterator[Couple[Object, nullable Object]] */;
3179 /* Covariant cast for argument 0 (i) <p0:Iterator[Couple[Object, nullable Object]]> isa Iterator[Couple[CoupleMapIterator#0, CoupleMapIterator#1]] */
3180 /* <p0:Iterator[Couple[Object, nullable Object]]> isa Iterator[Couple[CoupleMapIterator#0, CoupleMapIterator#1]] */
3181 type_struct
= self
->type
->resolution_table
->types
[COLOR_abstract_collection__Iteratorabstract_collection__Coupleabstract_collection__CoupleMapIterator_FT0abstract_collection__CoupleMapIterator_FT1
];
3182 cltype
= type_struct
->color
;
3183 idtype
= type_struct
->id
;
3184 if(cltype
>= p0
->type
->table_size
) {
3187 var
= p0
->type
->type_table
[cltype
] == idtype
;
3190 var_class_name
= p0
== NULL ?
"null" : p0
->type
->name
;
3191 fprintf(stderr
, "Runtime error: Cast failed. Expected `%s`, got `%s`", "Iterator[Couple[CoupleMapIterator#0, CoupleMapIterator#1]]", var_class_name
);
3192 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 560);
3196 self
->attrs
[COLOR_abstract_collection__CoupleMapIterator___iter
].val
= var_i
; /* _iter on <self:CoupleMapIterator[Object, nullable Object]> */
3199 /* method abstract_collection#CoupleMapIterator#init for (self: Object, Iterator[Couple[Object, nullable Object]]) */
3200 void VIRTUAL_abstract_collection__CoupleMapIterator__init(val
* self
, val
* p0
) {
3201 abstract_collection__CoupleMapIterator__init(self
, p0
);
3204 /* method abstract_collection#Couple#first for (self: Couple[nullable Object, nullable Object]): nullable Object */
3205 val
* abstract_collection__Couple__first(val
* self
) {
3206 val
* var
/* : nullable Object */;
3207 val
* var1
/* : nullable Object */;
3208 var1
= self
->attrs
[COLOR_abstract_collection__Couple___first
].val
; /* _first on <self:Couple[nullable Object, nullable Object]> */
3213 /* method abstract_collection#Couple#first for (self: Object): nullable Object */
3214 val
* VIRTUAL_abstract_collection__Couple__first(val
* self
) {
3215 val
* var
/* : nullable Object */;
3216 val
* var1
/* : nullable Object */;
3217 var1
= abstract_collection__Couple__first(self
);
3222 /* method abstract_collection#Couple#first= for (self: Couple[nullable Object, nullable Object], nullable Object) */
3223 void abstract_collection__Couple__first_61d(val
* self
, val
* p0
) {
3224 short int var
/* : Bool */;
3227 const struct type
* type_struct
;
3228 short int is_nullable
;
3229 const char* var_class_name
;
3230 /* Covariant cast for argument 0 (first) <p0:nullable Object> isa Couple#0 */
3231 /* <p0:nullable Object> isa Couple#0 */
3232 type_struct
= self
->type
->resolution_table
->types
[COLOR_abstract_collection__Couple_FT0
];
3233 cltype
= type_struct
->color
;
3234 idtype
= type_struct
->id
;
3235 is_nullable
= type_struct
->is_nullable
;
3239 if(cltype
>= p0
->type
->table_size
) {
3242 var
= p0
->type
->type_table
[cltype
] == idtype
;
3246 var_class_name
= p0
== NULL ?
"null" : p0
->type
->name
;
3247 fprintf(stderr
, "Runtime error: Cast failed. Expected `%s`, got `%s`", "Couple#0", var_class_name
);
3248 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 568);
3251 self
->attrs
[COLOR_abstract_collection__Couple___first
].val
= p0
; /* _first on <self:Couple[nullable Object, nullable Object]> */
3254 /* method abstract_collection#Couple#first= for (self: Object, nullable Object) */
3255 void VIRTUAL_abstract_collection__Couple__first_61d(val
* self
, val
* p0
) {
3256 abstract_collection__Couple__first_61d(self
, p0
);
3259 /* method abstract_collection#Couple#second for (self: Couple[nullable Object, nullable Object]): nullable Object */
3260 val
* abstract_collection__Couple__second(val
* self
) {
3261 val
* var
/* : nullable Object */;
3262 val
* var1
/* : nullable Object */;
3263 var1
= self
->attrs
[COLOR_abstract_collection__Couple___second
].val
; /* _second on <self:Couple[nullable Object, nullable Object]> */
3268 /* method abstract_collection#Couple#second for (self: Object): nullable Object */
3269 val
* VIRTUAL_abstract_collection__Couple__second(val
* self
) {
3270 val
* var
/* : nullable Object */;
3271 val
* var1
/* : nullable Object */;
3272 var1
= abstract_collection__Couple__second(self
);
3277 /* method abstract_collection#Couple#second= for (self: Couple[nullable Object, nullable Object], nullable Object) */
3278 void abstract_collection__Couple__second_61d(val
* self
, val
* p0
) {
3279 short int var
/* : Bool */;
3282 const struct type
* type_struct
;
3283 short int is_nullable
;
3284 const char* var_class_name
;
3285 /* Covariant cast for argument 0 (second) <p0:nullable Object> isa Couple#1 */
3286 /* <p0:nullable Object> isa Couple#1 */
3287 type_struct
= self
->type
->resolution_table
->types
[COLOR_abstract_collection__Couple_FT1
];
3288 cltype
= type_struct
->color
;
3289 idtype
= type_struct
->id
;
3290 is_nullable
= type_struct
->is_nullable
;
3294 if(cltype
>= p0
->type
->table_size
) {
3297 var
= p0
->type
->type_table
[cltype
] == idtype
;
3301 var_class_name
= p0
== NULL ?
"null" : p0
->type
->name
;
3302 fprintf(stderr
, "Runtime error: Cast failed. Expected `%s`, got `%s`", "Couple#1", var_class_name
);
3303 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 571);
3306 self
->attrs
[COLOR_abstract_collection__Couple___second
].val
= p0
; /* _second on <self:Couple[nullable Object, nullable Object]> */
3309 /* method abstract_collection#Couple#second= for (self: Object, nullable Object) */
3310 void VIRTUAL_abstract_collection__Couple__second_61d(val
* self
, val
* p0
) {
3311 abstract_collection__Couple__second_61d(self
, p0
);
3314 /* method abstract_collection#Couple#init for (self: Couple[nullable Object, nullable Object], nullable Object, nullable Object) */
3315 void abstract_collection__Couple__init(val
* self
, val
* p0
, val
* p1
) {
3316 short int var
/* : Bool */;
3319 const struct type
* type_struct
;
3320 short int is_nullable
;
3321 const char* var_class_name
;
3322 short int var1
/* : Bool */;
3325 const struct type
* type_struct4
;
3326 short int is_nullable5
;
3327 const char* var_class_name6
;
3328 val
* var_f
/* var f: nullable Object */;
3329 val
* var_s
/* var s: nullable Object */;
3330 /* Covariant cast for argument 0 (f) <p0:nullable Object> isa Couple#0 */
3331 /* <p0:nullable Object> isa Couple#0 */
3332 type_struct
= self
->type
->resolution_table
->types
[COLOR_abstract_collection__Couple_FT0
];
3333 cltype
= type_struct
->color
;
3334 idtype
= type_struct
->id
;
3335 is_nullable
= type_struct
->is_nullable
;
3339 if(cltype
>= p0
->type
->table_size
) {
3342 var
= p0
->type
->type_table
[cltype
] == idtype
;
3346 var_class_name
= p0
== NULL ?
"null" : p0
->type
->name
;
3347 fprintf(stderr
, "Runtime error: Cast failed. Expected `%s`, got `%s`", "Couple#0", var_class_name
);
3348 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 574);
3351 /* Covariant cast for argument 1 (s) <p1:nullable Object> isa Couple#1 */
3352 /* <p1:nullable Object> isa Couple#1 */
3353 type_struct4
= self
->type
->resolution_table
->types
[COLOR_abstract_collection__Couple_FT1
];
3354 cltype2
= type_struct4
->color
;
3355 idtype3
= type_struct4
->id
;
3356 is_nullable5
= type_struct4
->is_nullable
;
3358 var1
= is_nullable5
;
3360 if(cltype2
>= p1
->type
->table_size
) {
3363 var1
= p1
->type
->type_table
[cltype2
] == idtype3
;
3367 var_class_name6
= p1
== NULL ?
"null" : p1
->type
->name
;
3368 fprintf(stderr
, "Runtime error: Cast failed. Expected `%s`, got `%s`", "Couple#1", var_class_name6
);
3369 fprintf(stderr
, " (%s:%d)\n", "lib/standard/collection/abstract_collection.nit", 574);
3374 self
->attrs
[COLOR_abstract_collection__Couple___first
].val
= var_f
; /* _first on <self:Couple[nullable Object, nullable Object]> */
3375 self
->attrs
[COLOR_abstract_collection__Couple___second
].val
= var_s
; /* _second on <self:Couple[nullable Object, nullable Object]> */
3378 /* method abstract_collection#Couple#init for (self: Object, nullable Object, nullable Object) */
3379 void VIRTUAL_abstract_collection__Couple__init(val
* self
, val
* p0
, val
* p1
) {
3380 abstract_collection__Couple__init(self
, p0
, p1
);