1 #include "more_collections.sep.0.h"
2 /* method more_collections#MultiHashMap#add_one for (self: MultiHashMap[Object, nullable Object], Object, nullable Object) */
3 void more_collections__MultiHashMap__add_one(val
* self
, val
* p0
, val
* p1
) {
4 short int var
/* : Bool */;
7 const struct type
* type_struct
;
8 const char* var_class_name
;
9 short int var1
/* : Bool */;
12 const struct type
* type_struct4
;
13 short int is_nullable
;
14 const char* var_class_name5
;
15 val
* var_k
/* var k: Object */;
16 val
* var_v
/* var v: nullable Object */;
17 short int var6
/* : Bool */;
18 val
* var7
/* : nullable Object */;
19 val
* var8
/* : Array[nullable Object] */;
20 long var9
/* : Int */;
21 val
* var10
/* : NativeArray[nullable Object] */;
22 /* Covariant cast for argument 0 (k) <p0:Object> isa MultiHashMap#0 */
23 /* <p0:Object> isa MultiHashMap#0 */
24 type_struct
= self
->type
->resolution_table
->types
[COLOR_more_collections__MultiHashMap_FT0
];
25 cltype
= type_struct
->color
;
26 idtype
= type_struct
->id
;
27 if(cltype
>= p0
->type
->table_size
) {
30 var
= p0
->type
->type_table
[cltype
] == idtype
;
33 var_class_name
= p0
== NULL ?
"null" : p0
->type
->name
;
34 fprintf(stderr
, "Runtime error: Cast failed. Expected `%s`, got `%s`", "MultiHashMap#0", var_class_name
);
35 fprintf(stderr
, " (%s:%d)\n", "lib/more_collections.nit", 35);
38 /* Covariant cast for argument 1 (v) <p1:nullable Object> isa MultiHashMap#1 */
39 /* <p1:nullable Object> isa MultiHashMap#1 */
40 type_struct4
= self
->type
->resolution_table
->types
[COLOR_more_collections__MultiHashMap_FT1
];
41 cltype2
= type_struct4
->color
;
42 idtype3
= type_struct4
->id
;
43 is_nullable
= type_struct4
->is_nullable
;
47 if(cltype2
>= p1
->type
->table_size
) {
50 var1
= p1
->type
->type_table
[cltype2
] == idtype3
;
54 var_class_name5
= p1
== NULL ?
"null" : p1
->type
->name
;
55 fprintf(stderr
, "Runtime error: Cast failed. Expected `%s`, got `%s`", "MultiHashMap#1", var_class_name5
);
56 fprintf(stderr
, " (%s:%d)\n", "lib/more_collections.nit", 35);
61 var6
= ((short int (*)(val
*, val
*))(self
->class->vft
[COLOR_abstract_collection__MapRead__has_key
]))(self
, var_k
) /* has_key on <self:MultiHashMap[Object, nullable Object]>*/;
63 var7
= ((val
* (*)(val
*, val
*))(self
->class->vft
[COLOR_abstract_collection__MapRead___91d_93d
]))(self
, var_k
) /* [] on <self:MultiHashMap[Object, nullable Object]>*/;
64 ((void (*)(val
*, val
*))(var7
->class->vft
[COLOR_abstract_collection__SimpleCollection__add
]))(var7
, var_v
) /* add on <var7:nullable Object(Array[nullable Object])>*/;
66 var8
= NEW_array__Array(self
->type
->resolution_table
->types
[COLOR_array__Arraymore_collections__MultiHashMap_FT1
]);
67 { /* var8 = array_instance Array[MultiHashMap#1] */
69 var10
= NEW_array__NativeArray(var9
, self
->type
->resolution_table
->types
[COLOR_array__NativeArraymore_collections__MultiHashMap_FT1
]);
70 ((struct instance_array__NativeArray
*)var10
)->values
[0] = (val
*) var_v
;
71 ((void (*)(val
*, val
*, long))(var8
->class->vft
[COLOR_array__Array__with_native
]))(var8
, var10
, var9
) /* with_native on <var8:Array[nullable Object]>*/;
73 ((void (*)(val
*, val
*, val
*))(self
->class->vft
[COLOR_abstract_collection__Map___91d_93d_61d
]))(self
, var_k
, var8
) /* []= on <self:MultiHashMap[Object, nullable Object]>*/;
77 /* method more_collections#MultiHashMap#add_one for (self: Object, Object, nullable Object) */
78 void VIRTUAL_more_collections__MultiHashMap__add_one(val
* self
, val
* p0
, val
* p1
) {
79 more_collections__MultiHashMap__add_one(self
, p0
, p1
);
82 /* method more_collections#MultiHashMap#provide_default_value for (self: MultiHashMap[Object, nullable Object], Object): Array[nullable Object] */
83 val
* more_collections__MultiHashMap__provide_default_value(val
* self
, val
* p0
) {
84 val
* var
/* : Array[nullable Object] */;
85 short int var1
/* : Bool */;
88 const struct type
* type_struct
;
89 const char* var_class_name
;
90 val
* var_key
/* var key: Object */;
91 val
* var2
/* : Array[nullable Object] */;
92 val
* var_res
/* var res: Array[nullable Object] */;
93 /* Covariant cast for argument 0 (key) <p0:Object> isa MapRead#0 */
94 /* <p0:Object> isa MapRead#0 */
95 type_struct
= self
->type
->resolution_table
->types
[COLOR_abstract_collection__MapRead_FT0
];
96 cltype
= type_struct
->color
;
97 idtype
= type_struct
->id
;
98 if(cltype
>= p0
->type
->table_size
) {
101 var1
= p0
->type
->type_table
[cltype
] == idtype
;
104 var_class_name
= p0
== NULL ?
"null" : p0
->type
->name
;
105 fprintf(stderr
, "Runtime error: Cast failed. Expected `%s`, got `%s`", "MapRead#0", var_class_name
);
106 fprintf(stderr
, " (%s:%d)\n", "lib/more_collections.nit", 46);
110 var2
= NEW_array__Array(self
->type
->resolution_table
->types
[COLOR_array__Arraymore_collections__MultiHashMap_FT1
]);
111 ((void (*)(val
*))(var2
->class->vft
[COLOR_array__Array__init
]))(var2
) /* init on <var2:Array[nullable Object]>*/;
113 ((void (*)(val
*, val
*, val
*))(self
->class->vft
[COLOR_abstract_collection__Map___91d_93d_61d
]))(self
, var_key
, var_res
) /* []= on <self:MultiHashMap[Object, nullable Object]>*/;
119 /* method more_collections#MultiHashMap#provide_default_value for (self: Object, Object): nullable Object */
120 val
* VIRTUAL_more_collections__MultiHashMap__provide_default_value(val
* self
, val
* p0
) {
121 val
* var
/* : nullable Object */;
122 val
* var1
/* : Array[nullable Object] */;
123 var1
= more_collections__MultiHashMap__provide_default_value(self
, p0
);
128 /* method more_collections#MultiHashMap#init for (self: MultiHashMap[Object, nullable Object]) */
129 void more_collections__MultiHashMap__init(val
* self
) {
130 ((void (*)(val
*))(self
->class->vft
[COLOR_hash_collection__HashMap__init
]))(self
) /* init on <self:MultiHashMap[Object, nullable Object]>*/;
133 /* method more_collections#MultiHashMap#init for (self: Object) */
134 void VIRTUAL_more_collections__MultiHashMap__init(val
* self
) {
135 more_collections__MultiHashMap__init(self
);
138 /* method more_collections#HashMap2#level1 for (self: HashMap2[Object, Object, nullable Object]): HashMap[Object, HashMap[Object, nullable Object]] */
139 val
* more_collections__HashMap2__level1(val
* self
) {
140 val
* var
/* : HashMap[Object, HashMap[Object, nullable Object]] */;
141 val
* var1
/* : HashMap[Object, HashMap[Object, nullable Object]] */;
142 var1
= self
->attrs
[COLOR_more_collections__HashMap2___64dlevel1
].val
; /* @level1 on <self:HashMap2[Object, Object, nullable Object]> */
144 fprintf(stderr
, "Runtime error: %s", "Uninitialized attribute @level1");
145 fprintf(stderr
, " (%s:%d)\n", "lib/more_collections.nit", 57);
152 /* method more_collections#HashMap2#level1 for (self: Object): HashMap[Object, HashMap[Object, nullable Object]] */
153 val
* VIRTUAL_more_collections__HashMap2__level1(val
* self
) {
154 val
* var
/* : HashMap[Object, HashMap[Object, nullable Object]] */;
155 val
* var1
/* : HashMap[Object, HashMap[Object, nullable Object]] */;
156 var1
= more_collections__HashMap2__level1(self
);
161 /* method more_collections#HashMap2#level1= for (self: HashMap2[Object, Object, nullable Object], HashMap[Object, HashMap[Object, nullable Object]]) */
162 void more_collections__HashMap2__level1_61d(val
* self
, val
* p0
) {
163 short int var
/* : Bool */;
166 const struct type
* type_struct
;
167 const char* var_class_name
;
168 /* Covariant cast for argument 0 (level1) <p0:HashMap[Object, HashMap[Object, nullable Object]]> isa HashMap[HashMap2#0, HashMap[HashMap2#1, HashMap2#2]] */
169 /* <p0:HashMap[Object, HashMap[Object, nullable Object]]> isa HashMap[HashMap2#0, HashMap[HashMap2#1, HashMap2#2]] */
170 type_struct
= self
->type
->resolution_table
->types
[COLOR_hash_collection__HashMapmore_collections__HashMap2_FT0hash_collection__HashMapmore_collections__HashMap2_FT1more_collections__HashMap2_FT2
];
171 cltype
= type_struct
->color
;
172 idtype
= type_struct
->id
;
173 if(cltype
>= p0
->type
->table_size
) {
176 var
= p0
->type
->type_table
[cltype
] == idtype
;
179 var_class_name
= p0
== NULL ?
"null" : p0
->type
->name
;
180 fprintf(stderr
, "Runtime error: Cast failed. Expected `%s`, got `%s`", "HashMap[HashMap2#0, HashMap[HashMap2#1, HashMap2#2]]", var_class_name
);
181 fprintf(stderr
, " (%s:%d)\n", "lib/more_collections.nit", 57);
184 self
->attrs
[COLOR_more_collections__HashMap2___64dlevel1
].val
= p0
; /* @level1 on <self:HashMap2[Object, Object, nullable Object]> */
187 /* method more_collections#HashMap2#level1= for (self: Object, HashMap[Object, HashMap[Object, nullable Object]]) */
188 void VIRTUAL_more_collections__HashMap2__level1_61d(val
* self
, val
* p0
) {
189 more_collections__HashMap2__level1_61d(self
, p0
);
192 /* method more_collections#HashMap2#[] for (self: HashMap2[Object, Object, nullable Object], Object, Object): nullable Object */
193 val
* more_collections__HashMap2___91d_93d(val
* self
, val
* p0
, val
* p1
) {
194 val
* var
/* : nullable Object */;
195 short int var1
/* : Bool */;
198 const struct type
* type_struct
;
199 const char* var_class_name
;
200 short int var2
/* : Bool */;
203 const struct type
* type_struct5
;
204 const char* var_class_name6
;
205 val
* var_k1
/* var k1: Object */;
206 val
* var_k2
/* var k2: Object */;
207 val
* var7
/* : HashMap[Object, HashMap[Object, nullable Object]] */;
208 val
* var_level1
/* var level1: HashMap[Object, HashMap[Object, nullable Object]] */;
209 short int var8
/* : Bool */;
210 short int var9
/* : Bool */;
211 val
* var10
/* : null */;
212 val
* var11
/* : nullable Object */;
213 val
* var_level2
/* var level2: HashMap[Object, nullable Object] */;
214 short int var12
/* : Bool */;
215 short int var13
/* : Bool */;
216 val
* var14
/* : null */;
217 val
* var15
/* : nullable Object */;
218 /* Covariant cast for argument 0 (k1) <p0:Object> isa HashMap2#0 */
219 /* <p0:Object> isa HashMap2#0 */
220 type_struct
= self
->type
->resolution_table
->types
[COLOR_more_collections__HashMap2_FT0
];
221 cltype
= type_struct
->color
;
222 idtype
= type_struct
->id
;
223 if(cltype
>= p0
->type
->table_size
) {
226 var1
= p0
->type
->type_table
[cltype
] == idtype
;
229 var_class_name
= p0
== NULL ?
"null" : p0
->type
->name
;
230 fprintf(stderr
, "Runtime error: Cast failed. Expected `%s`, got `%s`", "HashMap2#0", var_class_name
);
231 fprintf(stderr
, " (%s:%d)\n", "lib/more_collections.nit", 59);
234 /* Covariant cast for argument 1 (k2) <p1:Object> isa HashMap2#1 */
235 /* <p1:Object> isa HashMap2#1 */
236 type_struct5
= self
->type
->resolution_table
->types
[COLOR_more_collections__HashMap2_FT1
];
237 cltype3
= type_struct5
->color
;
238 idtype4
= type_struct5
->id
;
239 if(cltype3
>= p1
->type
->table_size
) {
242 var2
= p1
->type
->type_table
[cltype3
] == idtype4
;
245 var_class_name6
= p1
== NULL ?
"null" : p1
->type
->name
;
246 fprintf(stderr
, "Runtime error: Cast failed. Expected `%s`, got `%s`", "HashMap2#1", var_class_name6
);
247 fprintf(stderr
, " (%s:%d)\n", "lib/more_collections.nit", 59);
252 var7
= ((val
* (*)(val
*))(self
->class->vft
[COLOR_more_collections__HashMap2__level1
]))(self
) /* level1 on <self:HashMap2[Object, Object, nullable Object]>*/;
254 var8
= ((short int (*)(val
*, val
*))(var_level1
->class->vft
[COLOR_abstract_collection__MapRead__has_key
]))(var_level1
, var_k1
) /* has_key on <var_level1:HashMap[Object, HashMap[Object, nullable Object]]>*/;
262 var11
= ((val
* (*)(val
*, val
*))(var_level1
->class->vft
[COLOR_abstract_collection__MapRead___91d_93d
]))(var_level1
, var_k1
) /* [] on <var_level1:HashMap[Object, HashMap[Object, nullable Object]]>*/;
264 var12
= ((short int (*)(val
*, val
*))(var_level2
->class->vft
[COLOR_abstract_collection__MapRead__has_key
]))(var_level2
, var_k2
) /* has_key on <var_level2:HashMap[Object, nullable Object]>*/;
272 var15
= ((val
* (*)(val
*, val
*))(var_level2
->class->vft
[COLOR_abstract_collection__MapRead___91d_93d
]))(var_level2
, var_k2
) /* [] on <var_level2:HashMap[Object, nullable Object]>*/;
278 /* method more_collections#HashMap2#[] for (self: Object, Object, Object): nullable Object */
279 val
* VIRTUAL_more_collections__HashMap2___91d_93d(val
* self
, val
* p0
, val
* p1
) {
280 val
* var
/* : nullable Object */;
281 val
* var1
/* : nullable Object */;
282 var1
= more_collections__HashMap2___91d_93d(self
, p0
, p1
);
287 /* method more_collections#HashMap2#[]= for (self: HashMap2[Object, Object, nullable Object], Object, Object, nullable Object) */
288 void more_collections__HashMap2___91d_93d_61d(val
* self
, val
* p0
, val
* p1
, val
* p2
) {
289 short int var
/* : Bool */;
292 const struct type
* type_struct
;
293 const char* var_class_name
;
294 short int var1
/* : Bool */;
297 const struct type
* type_struct4
;
298 const char* var_class_name5
;
299 short int var6
/* : Bool */;
302 const struct type
* type_struct9
;
303 short int is_nullable
;
304 const char* var_class_name10
;
305 val
* var_k1
/* var k1: Object */;
306 val
* var_k2
/* var k2: Object */;
307 val
* var_v
/* var v: nullable Object */;
308 val
* var11
/* : HashMap[Object, HashMap[Object, nullable Object]] */;
309 val
* var_level1
/* var level1: HashMap[Object, HashMap[Object, nullable Object]] */;
310 short int var12
/* : Bool */;
311 short int var13
/* : Bool */;
312 val
* var14
/* : HashMap[Object, nullable Object] */;
313 val
* var_level2
/* var level2: HashMap[Object, nullable Object] */;
314 val
* var15
/* : nullable Object */;
315 /* Covariant cast for argument 0 (k1) <p0:Object> isa HashMap2#0 */
316 /* <p0:Object> isa HashMap2#0 */
317 type_struct
= self
->type
->resolution_table
->types
[COLOR_more_collections__HashMap2_FT0
];
318 cltype
= type_struct
->color
;
319 idtype
= type_struct
->id
;
320 if(cltype
>= p0
->type
->table_size
) {
323 var
= p0
->type
->type_table
[cltype
] == idtype
;
326 var_class_name
= p0
== NULL ?
"null" : p0
->type
->name
;
327 fprintf(stderr
, "Runtime error: Cast failed. Expected `%s`, got `%s`", "HashMap2#0", var_class_name
);
328 fprintf(stderr
, " (%s:%d)\n", "lib/more_collections.nit", 70);
331 /* Covariant cast for argument 1 (k2) <p1:Object> isa HashMap2#1 */
332 /* <p1:Object> isa HashMap2#1 */
333 type_struct4
= self
->type
->resolution_table
->types
[COLOR_more_collections__HashMap2_FT1
];
334 cltype2
= type_struct4
->color
;
335 idtype3
= type_struct4
->id
;
336 if(cltype2
>= p1
->type
->table_size
) {
339 var1
= p1
->type
->type_table
[cltype2
] == idtype3
;
342 var_class_name5
= p1
== NULL ?
"null" : p1
->type
->name
;
343 fprintf(stderr
, "Runtime error: Cast failed. Expected `%s`, got `%s`", "HashMap2#1", var_class_name5
);
344 fprintf(stderr
, " (%s:%d)\n", "lib/more_collections.nit", 70);
347 /* Covariant cast for argument 2 (v) <p2:nullable Object> isa HashMap2#2 */
348 /* <p2:nullable Object> isa HashMap2#2 */
349 type_struct9
= self
->type
->resolution_table
->types
[COLOR_more_collections__HashMap2_FT2
];
350 cltype7
= type_struct9
->color
;
351 idtype8
= type_struct9
->id
;
352 is_nullable
= type_struct9
->is_nullable
;
356 if(cltype7
>= p2
->type
->table_size
) {
359 var6
= p2
->type
->type_table
[cltype7
] == idtype8
;
363 var_class_name10
= p2
== NULL ?
"null" : p2
->type
->name
;
364 fprintf(stderr
, "Runtime error: Cast failed. Expected `%s`, got `%s`", "HashMap2#2", var_class_name10
);
365 fprintf(stderr
, " (%s:%d)\n", "lib/more_collections.nit", 70);
371 var11
= ((val
* (*)(val
*))(self
->class->vft
[COLOR_more_collections__HashMap2__level1
]))(self
) /* level1 on <self:HashMap2[Object, Object, nullable Object]>*/;
373 var12
= ((short int (*)(val
*, val
*))(var_level1
->class->vft
[COLOR_abstract_collection__MapRead__has_key
]))(var_level1
, var_k1
) /* has_key on <var_level1:HashMap[Object, HashMap[Object, nullable Object]]>*/;
376 var14
= NEW_hash_collection__HashMap(self
->type
->resolution_table
->types
[COLOR_hash_collection__HashMapmore_collections__HashMap2_FT1more_collections__HashMap2_FT2
]);
377 ((void (*)(val
*))(var14
->class->vft
[COLOR_hash_collection__HashMap__init
]))(var14
) /* init on <var14:HashMap[Object, nullable Object]>*/;
379 ((void (*)(val
*, val
*, val
*))(var_level1
->class->vft
[COLOR_abstract_collection__Map___91d_93d_61d
]))(var_level1
, var_k1
, var_level2
) /* []= on <var_level1:HashMap[Object, HashMap[Object, nullable Object]]>*/;
381 var15
= ((val
* (*)(val
*, val
*))(var_level1
->class->vft
[COLOR_abstract_collection__MapRead___91d_93d
]))(var_level1
, var_k1
) /* [] on <var_level1:HashMap[Object, HashMap[Object, nullable Object]]>*/;
384 ((void (*)(val
*, val
*, val
*))(var_level2
->class->vft
[COLOR_abstract_collection__Map___91d_93d_61d
]))(var_level2
, var_k2
, var_v
) /* []= on <var_level2:HashMap[Object, nullable Object]>*/;
387 /* method more_collections#HashMap2#[]= for (self: Object, Object, Object, nullable Object) */
388 void VIRTUAL_more_collections__HashMap2___91d_93d_61d(val
* self
, val
* p0
, val
* p1
, val
* p2
) {
389 more_collections__HashMap2___91d_93d_61d(self
, p0
, p1
, p2
);
392 /* method more_collections#HashMap2#init for (self: HashMap2[Object, Object, nullable Object]) */
393 void more_collections__HashMap2__init(val
* self
) {
396 /* method more_collections#HashMap2#init for (self: Object) */
397 void VIRTUAL_more_collections__HashMap2__init(val
* self
) {
398 more_collections__HashMap2__init(self
);
401 /* method more_collections#HashMap3#level1 for (self: HashMap3[Object, Object, Object, nullable Object]): HashMap[Object, HashMap2[Object, Object, nullable Object]] */
402 val
* more_collections__HashMap3__level1(val
* self
) {
403 val
* var
/* : HashMap[Object, HashMap2[Object, Object, nullable Object]] */;
404 val
* var1
/* : HashMap[Object, HashMap2[Object, Object, nullable Object]] */;
405 var1
= self
->attrs
[COLOR_more_collections__HashMap3___64dlevel1
].val
; /* @level1 on <self:HashMap3[Object, Object, Object, nullable Object]> */
407 fprintf(stderr
, "Runtime error: %s", "Uninitialized attribute @level1");
408 fprintf(stderr
, " (%s:%d)\n", "lib/more_collections.nit", 87);
415 /* method more_collections#HashMap3#level1 for (self: Object): HashMap[Object, HashMap2[Object, Object, nullable Object]] */
416 val
* VIRTUAL_more_collections__HashMap3__level1(val
* self
) {
417 val
* var
/* : HashMap[Object, HashMap2[Object, Object, nullable Object]] */;
418 val
* var1
/* : HashMap[Object, HashMap2[Object, Object, nullable Object]] */;
419 var1
= more_collections__HashMap3__level1(self
);
424 /* method more_collections#HashMap3#level1= for (self: HashMap3[Object, Object, Object, nullable Object], HashMap[Object, HashMap2[Object, Object, nullable Object]]) */
425 void more_collections__HashMap3__level1_61d(val
* self
, val
* p0
) {
426 short int var
/* : Bool */;
429 const struct type
* type_struct
;
430 const char* var_class_name
;
431 /* Covariant cast for argument 0 (level1) <p0:HashMap[Object, HashMap2[Object, Object, nullable Object]]> isa HashMap[HashMap3#0, HashMap2[HashMap3#1, HashMap3#2, HashMap3#3]] */
432 /* <p0:HashMap[Object, HashMap2[Object, Object, nullable Object]]> isa HashMap[HashMap3#0, HashMap2[HashMap3#1, HashMap3#2, HashMap3#3]] */
433 type_struct
= self
->type
->resolution_table
->types
[COLOR_hash_collection__HashMapmore_collections__HashMap3_FT0more_collections__HashMap2more_collections__HashMap3_FT1more_collections__HashMap3_FT2more_collections__HashMap3_FT3
];
434 cltype
= type_struct
->color
;
435 idtype
= type_struct
->id
;
436 if(cltype
>= p0
->type
->table_size
) {
439 var
= p0
->type
->type_table
[cltype
] == idtype
;
442 var_class_name
= p0
== NULL ?
"null" : p0
->type
->name
;
443 fprintf(stderr
, "Runtime error: Cast failed. Expected `%s`, got `%s`", "HashMap[HashMap3#0, HashMap2[HashMap3#1, HashMap3#2, HashMap3#3]]", var_class_name
);
444 fprintf(stderr
, " (%s:%d)\n", "lib/more_collections.nit", 87);
447 self
->attrs
[COLOR_more_collections__HashMap3___64dlevel1
].val
= p0
; /* @level1 on <self:HashMap3[Object, Object, Object, nullable Object]> */
450 /* method more_collections#HashMap3#level1= for (self: Object, HashMap[Object, HashMap2[Object, Object, nullable Object]]) */
451 void VIRTUAL_more_collections__HashMap3__level1_61d(val
* self
, val
* p0
) {
452 more_collections__HashMap3__level1_61d(self
, p0
);
455 /* method more_collections#HashMap3#[] for (self: HashMap3[Object, Object, Object, nullable Object], Object, Object, Object): nullable Object */
456 val
* more_collections__HashMap3___91d_93d(val
* self
, val
* p0
, val
* p1
, val
* p2
) {
457 val
* var
/* : nullable Object */;
458 short int var1
/* : Bool */;
461 const struct type
* type_struct
;
462 const char* var_class_name
;
463 short int var2
/* : Bool */;
466 const struct type
* type_struct5
;
467 const char* var_class_name6
;
468 short int var7
/* : Bool */;
471 const struct type
* type_struct10
;
472 const char* var_class_name11
;
473 val
* var_k1
/* var k1: Object */;
474 val
* var_k2
/* var k2: Object */;
475 val
* var_k3
/* var k3: Object */;
476 val
* var12
/* : HashMap[Object, HashMap2[Object, Object, nullable Object]] */;
477 val
* var_level1
/* var level1: HashMap[Object, HashMap2[Object, Object, nullable Object]] */;
478 short int var13
/* : Bool */;
479 short int var14
/* : Bool */;
480 val
* var15
/* : null */;
481 val
* var16
/* : nullable Object */;
482 val
* var_level2
/* var level2: HashMap2[Object, Object, nullable Object] */;
483 val
* var17
/* : nullable Object */;
484 /* Covariant cast for argument 0 (k1) <p0:Object> isa HashMap3#0 */
485 /* <p0:Object> isa HashMap3#0 */
486 type_struct
= self
->type
->resolution_table
->types
[COLOR_more_collections__HashMap3_FT0
];
487 cltype
= type_struct
->color
;
488 idtype
= type_struct
->id
;
489 if(cltype
>= p0
->type
->table_size
) {
492 var1
= p0
->type
->type_table
[cltype
] == idtype
;
495 var_class_name
= p0
== NULL ?
"null" : p0
->type
->name
;
496 fprintf(stderr
, "Runtime error: Cast failed. Expected `%s`, got `%s`", "HashMap3#0", var_class_name
);
497 fprintf(stderr
, " (%s:%d)\n", "lib/more_collections.nit", 89);
500 /* Covariant cast for argument 1 (k2) <p1:Object> isa HashMap3#1 */
501 /* <p1:Object> isa HashMap3#1 */
502 type_struct5
= self
->type
->resolution_table
->types
[COLOR_more_collections__HashMap3_FT1
];
503 cltype3
= type_struct5
->color
;
504 idtype4
= type_struct5
->id
;
505 if(cltype3
>= p1
->type
->table_size
) {
508 var2
= p1
->type
->type_table
[cltype3
] == idtype4
;
511 var_class_name6
= p1
== NULL ?
"null" : p1
->type
->name
;
512 fprintf(stderr
, "Runtime error: Cast failed. Expected `%s`, got `%s`", "HashMap3#1", var_class_name6
);
513 fprintf(stderr
, " (%s:%d)\n", "lib/more_collections.nit", 89);
516 /* Covariant cast for argument 2 (k3) <p2:Object> isa HashMap3#2 */
517 /* <p2:Object> isa HashMap3#2 */
518 type_struct10
= self
->type
->resolution_table
->types
[COLOR_more_collections__HashMap3_FT2
];
519 cltype8
= type_struct10
->color
;
520 idtype9
= type_struct10
->id
;
521 if(cltype8
>= p2
->type
->table_size
) {
524 var7
= p2
->type
->type_table
[cltype8
] == idtype9
;
527 var_class_name11
= p2
== NULL ?
"null" : p2
->type
->name
;
528 fprintf(stderr
, "Runtime error: Cast failed. Expected `%s`, got `%s`", "HashMap3#2", var_class_name11
);
529 fprintf(stderr
, " (%s:%d)\n", "lib/more_collections.nit", 89);
535 var12
= ((val
* (*)(val
*))(self
->class->vft
[COLOR_more_collections__HashMap3__level1
]))(self
) /* level1 on <self:HashMap3[Object, Object, Object, nullable Object]>*/;
537 var13
= ((short int (*)(val
*, val
*))(var_level1
->class->vft
[COLOR_abstract_collection__MapRead__has_key
]))(var_level1
, var_k1
) /* has_key on <var_level1:HashMap[Object, HashMap2[Object, Object, nullable Object]]>*/;
545 var16
= ((val
* (*)(val
*, val
*))(var_level1
->class->vft
[COLOR_abstract_collection__MapRead___91d_93d
]))(var_level1
, var_k1
) /* [] on <var_level1:HashMap[Object, HashMap2[Object, Object, nullable Object]]>*/;
547 var17
= ((val
* (*)(val
*, val
*, val
*))(var_level2
->class->vft
[COLOR_more_collections__HashMap2___91d_93d
]))(var_level2
, var_k2
, var_k3
) /* [] on <var_level2:HashMap2[Object, Object, nullable Object]>*/;
553 /* method more_collections#HashMap3#[] for (self: Object, Object, Object, Object): nullable Object */
554 val
* VIRTUAL_more_collections__HashMap3___91d_93d(val
* self
, val
* p0
, val
* p1
, val
* p2
) {
555 val
* var
/* : nullable Object */;
556 val
* var1
/* : nullable Object */;
557 var1
= more_collections__HashMap3___91d_93d(self
, p0
, p1
, p2
);
562 /* method more_collections#HashMap3#[]= for (self: HashMap3[Object, Object, Object, nullable Object], Object, Object, Object, nullable Object) */
563 void more_collections__HashMap3___91d_93d_61d(val
* self
, val
* p0
, val
* p1
, val
* p2
, val
* p3
) {
564 short int var
/* : Bool */;
567 const struct type
* type_struct
;
568 const char* var_class_name
;
569 short int var1
/* : Bool */;
572 const struct type
* type_struct4
;
573 const char* var_class_name5
;
574 short int var6
/* : Bool */;
577 const struct type
* type_struct9
;
578 const char* var_class_name10
;
579 short int var11
/* : Bool */;
582 const struct type
* type_struct14
;
583 short int is_nullable
;
584 const char* var_class_name15
;
585 val
* var_k1
/* var k1: Object */;
586 val
* var_k2
/* var k2: Object */;
587 val
* var_k3
/* var k3: Object */;
588 val
* var_v
/* var v: nullable Object */;
589 val
* var16
/* : HashMap[Object, HashMap2[Object, Object, nullable Object]] */;
590 val
* var_level1
/* var level1: HashMap[Object, HashMap2[Object, Object, nullable Object]] */;
591 short int var17
/* : Bool */;
592 short int var18
/* : Bool */;
593 val
* var19
/* : HashMap2[Object, Object, nullable Object] */;
594 val
* var_level2
/* var level2: HashMap2[Object, Object, nullable Object] */;
595 val
* var20
/* : nullable Object */;
596 /* Covariant cast for argument 0 (k1) <p0:Object> isa HashMap3#0 */
597 /* <p0:Object> isa HashMap3#0 */
598 type_struct
= self
->type
->resolution_table
->types
[COLOR_more_collections__HashMap3_FT0
];
599 cltype
= type_struct
->color
;
600 idtype
= type_struct
->id
;
601 if(cltype
>= p0
->type
->table_size
) {
604 var
= p0
->type
->type_table
[cltype
] == idtype
;
607 var_class_name
= p0
== NULL ?
"null" : p0
->type
->name
;
608 fprintf(stderr
, "Runtime error: Cast failed. Expected `%s`, got `%s`", "HashMap3#0", var_class_name
);
609 fprintf(stderr
, " (%s:%d)\n", "lib/more_collections.nit", 99);
612 /* Covariant cast for argument 1 (k2) <p1:Object> isa HashMap3#1 */
613 /* <p1:Object> isa HashMap3#1 */
614 type_struct4
= self
->type
->resolution_table
->types
[COLOR_more_collections__HashMap3_FT1
];
615 cltype2
= type_struct4
->color
;
616 idtype3
= type_struct4
->id
;
617 if(cltype2
>= p1
->type
->table_size
) {
620 var1
= p1
->type
->type_table
[cltype2
] == idtype3
;
623 var_class_name5
= p1
== NULL ?
"null" : p1
->type
->name
;
624 fprintf(stderr
, "Runtime error: Cast failed. Expected `%s`, got `%s`", "HashMap3#1", var_class_name5
);
625 fprintf(stderr
, " (%s:%d)\n", "lib/more_collections.nit", 99);
628 /* Covariant cast for argument 2 (k3) <p2:Object> isa HashMap3#2 */
629 /* <p2:Object> isa HashMap3#2 */
630 type_struct9
= self
->type
->resolution_table
->types
[COLOR_more_collections__HashMap3_FT2
];
631 cltype7
= type_struct9
->color
;
632 idtype8
= type_struct9
->id
;
633 if(cltype7
>= p2
->type
->table_size
) {
636 var6
= p2
->type
->type_table
[cltype7
] == idtype8
;
639 var_class_name10
= p2
== NULL ?
"null" : p2
->type
->name
;
640 fprintf(stderr
, "Runtime error: Cast failed. Expected `%s`, got `%s`", "HashMap3#2", var_class_name10
);
641 fprintf(stderr
, " (%s:%d)\n", "lib/more_collections.nit", 99);
644 /* Covariant cast for argument 3 (v) <p3:nullable Object> isa HashMap3#3 */
645 /* <p3:nullable Object> isa HashMap3#3 */
646 type_struct14
= self
->type
->resolution_table
->types
[COLOR_more_collections__HashMap3_FT3
];
647 cltype12
= type_struct14
->color
;
648 idtype13
= type_struct14
->id
;
649 is_nullable
= type_struct14
->is_nullable
;
653 if(cltype12
>= p3
->type
->table_size
) {
656 var11
= p3
->type
->type_table
[cltype12
] == idtype13
;
660 var_class_name15
= p3
== NULL ?
"null" : p3
->type
->name
;
661 fprintf(stderr
, "Runtime error: Cast failed. Expected `%s`, got `%s`", "HashMap3#3", var_class_name15
);
662 fprintf(stderr
, " (%s:%d)\n", "lib/more_collections.nit", 99);
669 var16
= ((val
* (*)(val
*))(self
->class->vft
[COLOR_more_collections__HashMap3__level1
]))(self
) /* level1 on <self:HashMap3[Object, Object, Object, nullable Object]>*/;
671 var17
= ((short int (*)(val
*, val
*))(var_level1
->class->vft
[COLOR_abstract_collection__MapRead__has_key
]))(var_level1
, var_k1
) /* has_key on <var_level1:HashMap[Object, HashMap2[Object, Object, nullable Object]]>*/;
674 var19
= NEW_more_collections__HashMap2(self
->type
->resolution_table
->types
[COLOR_more_collections__HashMap2more_collections__HashMap3_FT1more_collections__HashMap3_FT2more_collections__HashMap3_FT3
]);
675 ((void (*)(val
*))(var19
->class->vft
[COLOR_more_collections__HashMap2__init
]))(var19
) /* init on <var19:HashMap2[Object, Object, nullable Object]>*/;
677 ((void (*)(val
*, val
*, val
*))(var_level1
->class->vft
[COLOR_abstract_collection__Map___91d_93d_61d
]))(var_level1
, var_k1
, var_level2
) /* []= on <var_level1:HashMap[Object, HashMap2[Object, Object, nullable Object]]>*/;
679 var20
= ((val
* (*)(val
*, val
*))(var_level1
->class->vft
[COLOR_abstract_collection__MapRead___91d_93d
]))(var_level1
, var_k1
) /* [] on <var_level1:HashMap[Object, HashMap2[Object, Object, nullable Object]]>*/;
682 ((void (*)(val
*, val
*, val
*, val
*))(var_level2
->class->vft
[COLOR_more_collections__HashMap2___91d_93d_61d
]))(var_level2
, var_k2
, var_k3
, var_v
) /* []= on <var_level2:HashMap2[Object, Object, nullable Object]>*/;
685 /* method more_collections#HashMap3#[]= for (self: Object, Object, Object, Object, nullable Object) */
686 void VIRTUAL_more_collections__HashMap3___91d_93d_61d(val
* self
, val
* p0
, val
* p1
, val
* p2
, val
* p3
) {
687 more_collections__HashMap3___91d_93d_61d(self
, p0
, p1
, p2
, p3
);
690 /* method more_collections#HashMap3#init for (self: HashMap3[Object, Object, Object, nullable Object]) */
691 void more_collections__HashMap3__init(val
* self
) {
694 /* method more_collections#HashMap3#init for (self: Object) */
695 void VIRTUAL_more_collections__HashMap3__init(val
* self
) {
696 more_collections__HashMap3__init(self
);