1 /* This C file is generated by NIT to compile module standard___collection___list. */
2 #include "standard___collection___list._sep.h"
3 static const char LOCATE_standard___collection___list___List_____bra
[] = "list::List::(abstract_collection::SequenceRead::[])";
4 val_t
standard___collection___list___List_____bra(val_t p0
, val_t p1
){
5 struct {struct stack_frame_t me
;} fra
;
8 fra
.me
.prev
= stack_frame_head
; stack_frame_head
= &fra
.me
;
9 fra
.me
.file
= LOCATE_standard___collection___list
;
11 fra
.me
.meth
= LOCATE_standard___collection___list___List_____bra
;
14 fra
.me
.nitni_local_ref_head
= NULL
;
15 fra
.me
.REG
[0] = NIT_NULL
;
18 /* ../lib/standard/collection/list.nit:22 */
19 fra
.me
.REG
[0] = CALL_standard___collection___list___List___get_node(fra
.me
.REG
[0])(fra
.me
.REG
[0], REGB0
);
20 REGB0
= TAG_Bool(fra
.me
.REG
[0]==NIT_NULL
);
21 if (UNTAG_Bool(REGB0
)) {
22 nit_abort("Reciever is null", NULL
, LOCATE_standard___collection___list
, 22);
24 fra
.me
.REG
[0] = CALL_standard___collection___abstract_collection___Container___item(fra
.me
.REG
[0])(fra
.me
.REG
[0]);
27 stack_frame_head
= fra
.me
.prev
;
30 static const char LOCATE_standard___collection___list___List_____braeq
[] = "list::List::(abstract_collection::Sequence::[]=)";
31 void standard___collection___list___List_____braeq(val_t p0
, val_t p1
, val_t p2
){
32 struct {struct stack_frame_t me
; val_t MORE_REG
[1];} fra
;
35 fra
.me
.prev
= stack_frame_head
; stack_frame_head
= &fra
.me
;
36 fra
.me
.file
= LOCATE_standard___collection___list
;
38 fra
.me
.meth
= LOCATE_standard___collection___list___List_____braeq
;
41 fra
.me
.nitni_local_ref_head
= NULL
;
42 fra
.me
.REG
[0] = NIT_NULL
;
43 fra
.me
.REG
[1] = NIT_NULL
;
47 /* ../lib/standard/collection/list.nit:24 */
48 fra
.me
.REG
[0] = CALL_standard___collection___list___List___get_node(fra
.me
.REG
[0])(fra
.me
.REG
[0], REGB0
);
49 REGB0
= TAG_Bool(fra
.me
.REG
[0]==NIT_NULL
);
50 if (UNTAG_Bool(REGB0
)) {
51 nit_abort("Reciever is null", NULL
, LOCATE_standard___collection___list
, 24);
53 CALL_standard___collection___abstract_collection___Container___item__eq(fra
.me
.REG
[0])(fra
.me
.REG
[0], fra
.me
.REG
[1]);
54 stack_frame_head
= fra
.me
.prev
;
57 static const char LOCATE_standard___collection___list___List___first
[] = "list::List::(abstract_collection::Collection::first)";
58 val_t
standard___collection___list___List___first(val_t p0
){
59 struct {struct stack_frame_t me
;} fra
;
62 fra
.me
.prev
= stack_frame_head
; stack_frame_head
= &fra
.me
;
63 fra
.me
.file
= LOCATE_standard___collection___list
;
65 fra
.me
.meth
= LOCATE_standard___collection___list___List___first
;
68 fra
.me
.nitni_local_ref_head
= NULL
;
69 fra
.me
.REG
[0] = NIT_NULL
;
71 /* ../lib/standard/collection/list.nit:27 */
72 fra
.me
.REG
[0] = ATTR_standard___collection___list___List____head(fra
.me
.REG
[0]);
73 REGB0
= TAG_Bool(fra
.me
.REG
[0]==NIT_NULL
);
74 if (UNTAG_Bool(REGB0
)) {
75 nit_abort("Reciever is null", NULL
, LOCATE_standard___collection___list
, 27);
77 fra
.me
.REG
[0] = CALL_standard___collection___abstract_collection___Container___item(fra
.me
.REG
[0])(fra
.me
.REG
[0]);
80 stack_frame_head
= fra
.me
.prev
;
83 static const char LOCATE_standard___collection___list___List___first__eq
[] = "list::List::(abstract_collection::Sequence::first=)";
84 void standard___collection___list___List___first__eq(val_t p0
, val_t p1
){
85 struct {struct stack_frame_t me
; val_t MORE_REG
[1];} fra
;
88 fra
.me
.prev
= stack_frame_head
; stack_frame_head
= &fra
.me
;
89 fra
.me
.file
= LOCATE_standard___collection___list
;
91 fra
.me
.meth
= LOCATE_standard___collection___list___List___first__eq
;
94 fra
.me
.nitni_local_ref_head
= NULL
;
95 fra
.me
.REG
[0] = NIT_NULL
;
96 fra
.me
.REG
[1] = NIT_NULL
;
99 /* ../lib/standard/collection/list.nit:30 */
100 fra
.me
.REG
[0] = ATTR_standard___collection___list___List____head(fra
.me
.REG
[0]);
101 REGB0
= TAG_Bool(fra
.me
.REG
[0]==NIT_NULL
);
102 if (UNTAG_Bool(REGB0
)) {
103 nit_abort("Reciever is null", NULL
, LOCATE_standard___collection___list
, 30);
105 CALL_standard___collection___abstract_collection___Container___item__eq(fra
.me
.REG
[0])(fra
.me
.REG
[0], fra
.me
.REG
[1]);
106 stack_frame_head
= fra
.me
.prev
;
109 static const char LOCATE_standard___collection___list___List___last
[] = "list::List::(abstract_collection::SequenceRead::last)";
110 val_t
standard___collection___list___List___last(val_t p0
){
111 struct {struct stack_frame_t me
;} fra
;
114 fra
.me
.prev
= stack_frame_head
; stack_frame_head
= &fra
.me
;
115 fra
.me
.file
= LOCATE_standard___collection___list
;
117 fra
.me
.meth
= LOCATE_standard___collection___list___List___last
;
118 fra
.me
.has_broke
= 0;
120 fra
.me
.nitni_local_ref_head
= NULL
;
121 fra
.me
.REG
[0] = NIT_NULL
;
123 /* ../lib/standard/collection/list.nit:33 */
124 fra
.me
.REG
[0] = ATTR_standard___collection___list___List____tail(fra
.me
.REG
[0]);
125 REGB0
= TAG_Bool(fra
.me
.REG
[0]==NIT_NULL
);
126 if (UNTAG_Bool(REGB0
)) {
127 nit_abort("Reciever is null", NULL
, LOCATE_standard___collection___list
, 33);
129 fra
.me
.REG
[0] = CALL_standard___collection___abstract_collection___Container___item(fra
.me
.REG
[0])(fra
.me
.REG
[0]);
132 stack_frame_head
= fra
.me
.prev
;
133 return fra
.me
.REG
[0];
135 static const char LOCATE_standard___collection___list___List___last__eq
[] = "list::List::(abstract_collection::Sequence::last=)";
136 void standard___collection___list___List___last__eq(val_t p0
, val_t p1
){
137 struct {struct stack_frame_t me
; val_t MORE_REG
[1];} fra
;
140 fra
.me
.prev
= stack_frame_head
; stack_frame_head
= &fra
.me
;
141 fra
.me
.file
= LOCATE_standard___collection___list
;
143 fra
.me
.meth
= LOCATE_standard___collection___list___List___last__eq
;
144 fra
.me
.has_broke
= 0;
146 fra
.me
.nitni_local_ref_head
= NULL
;
147 fra
.me
.REG
[0] = NIT_NULL
;
148 fra
.me
.REG
[1] = NIT_NULL
;
151 /* ../lib/standard/collection/list.nit:36 */
152 fra
.me
.REG
[0] = ATTR_standard___collection___list___List____tail(fra
.me
.REG
[0]);
153 REGB0
= TAG_Bool(fra
.me
.REG
[0]==NIT_NULL
);
154 if (UNTAG_Bool(REGB0
)) {
155 nit_abort("Reciever is null", NULL
, LOCATE_standard___collection___list
, 36);
157 CALL_standard___collection___abstract_collection___Container___item__eq(fra
.me
.REG
[0])(fra
.me
.REG
[0], fra
.me
.REG
[1]);
158 stack_frame_head
= fra
.me
.prev
;
161 static const char LOCATE_standard___collection___list___List___is_empty
[] = "list::List::(abstract_collection::Collection::is_empty)";
162 val_t
standard___collection___list___List___is_empty(val_t p0
){
163 struct {struct stack_frame_t me
;} fra
;
167 fra
.me
.prev
= stack_frame_head
; stack_frame_head
= &fra
.me
;
168 fra
.me
.file
= LOCATE_standard___collection___list
;
170 fra
.me
.meth
= LOCATE_standard___collection___list___List___is_empty
;
171 fra
.me
.has_broke
= 0;
173 fra
.me
.nitni_local_ref_head
= NULL
;
174 fra
.me
.REG
[0] = NIT_NULL
;
176 /* ../lib/standard/collection/list.nit:41 */
177 fra
.me
.REG
[0] = ATTR_standard___collection___list___List____head(fra
.me
.REG
[0]);
178 REGB0
= TAG_Bool(fra
.me
.REG
[0]==NIT_NULL
);
179 if (UNTAG_Bool(REGB0
)) {
181 REGB1
= TAG_Bool(fra
.me
.REG
[0]==NIT_NULL
);
182 if (UNTAG_Bool(REGB1
)) {
186 REGB1
= CALL_standard___kernel___Object_____eqeq(fra
.me
.REG
[0])(fra
.me
.REG
[0], NIT_NULL
);
192 stack_frame_head
= fra
.me
.prev
;
195 static const char LOCATE_standard___collection___list___List___length
[] = "list::List::(abstract_collection::Collection::length)";
196 val_t
standard___collection___list___List___length(val_t p0
){
197 struct {struct stack_frame_t me
; val_t MORE_REG
[1];} fra
;
202 fra
.me
.prev
= stack_frame_head
; stack_frame_head
= &fra
.me
;
203 fra
.me
.file
= LOCATE_standard___collection___list
;
205 fra
.me
.meth
= LOCATE_standard___collection___list___List___length
;
206 fra
.me
.has_broke
= 0;
208 fra
.me
.nitni_local_ref_head
= NULL
;
209 fra
.me
.REG
[0] = NIT_NULL
;
210 fra
.me
.REG
[1] = NIT_NULL
;
212 /* ../lib/standard/collection/list.nit:46 */
214 /* ../lib/standard/collection/list.nit:47 */
215 fra
.me
.REG
[0] = ATTR_standard___collection___list___List____head(fra
.me
.REG
[0]);
216 /* ../lib/standard/collection/list.nit:48 */
218 REGB1
= TAG_Bool(fra
.me
.REG
[0]==NIT_NULL
);
219 if (UNTAG_Bool(REGB1
)) {
221 REGB2
= TAG_Bool(fra
.me
.REG
[0]==NIT_NULL
);
222 if (UNTAG_Bool(REGB2
)) {
226 REGB2
= CALL_standard___kernel___Object_____eqeq(fra
.me
.REG
[0])(fra
.me
.REG
[0], NIT_NULL
);
230 REGB1
= TAG_Bool(!UNTAG_Bool(REGB1
));
231 if (UNTAG_Bool(REGB1
)) {
232 /* ../lib/standard/collection/list.nit:49 */
234 /* ../lib/standard/kernel.nit:238 */
235 REGB1
= TAG_Int(UNTAG_Int(REGB0
)+UNTAG_Int(REGB1
));
236 /* ../lib/standard/collection/list.nit:49 */
238 /* ../lib/standard/collection/list.nit:50 */
239 REGB1
= TAG_Bool(fra
.me
.REG
[0]==NIT_NULL
);
240 if (UNTAG_Bool(REGB1
)) {
241 nit_abort("Reciever is null", NULL
, LOCATE_standard___collection___list
, 50);
243 fra
.me
.REG
[1] = CALL_standard___collection___list___ListNode___next(fra
.me
.REG
[0])(fra
.me
.REG
[0]);
244 fra
.me
.REG
[0] = fra
.me
.REG
[1];
246 /* ../lib/standard/collection/list.nit:48 */
251 /* ../lib/standard/collection/list.nit:52 */
254 stack_frame_head
= fra
.me
.prev
;
257 static const char LOCATE_standard___collection___list___List___has
[] = "list::List::(abstract_collection::Collection::has)";
258 val_t
standard___collection___list___List___has(val_t p0
, val_t p1
){
259 struct {struct stack_frame_t me
; val_t MORE_REG
[2];} fra
;
263 fra
.me
.prev
= stack_frame_head
; stack_frame_head
= &fra
.me
;
264 fra
.me
.file
= LOCATE_standard___collection___list
;
266 fra
.me
.meth
= LOCATE_standard___collection___list___List___has
;
267 fra
.me
.has_broke
= 0;
269 fra
.me
.nitni_local_ref_head
= NULL
;
270 fra
.me
.REG
[0] = NIT_NULL
;
271 fra
.me
.REG
[1] = NIT_NULL
;
272 fra
.me
.REG
[2] = NIT_NULL
;
275 /* ../lib/standard/collection/list.nit:56 */
276 fra
.me
.REG
[2] = ATTR_standard___collection___list___List____head(fra
.me
.REG
[0]);
277 fra
.me
.REG
[2] = CALL_standard___collection___list___List___search_node_after(fra
.me
.REG
[0])(fra
.me
.REG
[0], fra
.me
.REG
[1], fra
.me
.REG
[2]);
278 REGB0
= TAG_Bool(fra
.me
.REG
[2]==NIT_NULL
);
279 if (UNTAG_Bool(REGB0
)) {
281 REGB1
= TAG_Bool(fra
.me
.REG
[2]==NIT_NULL
);
282 if (UNTAG_Bool(REGB1
)) {
286 REGB1
= CALL_standard___kernel___Object_____eqeq(fra
.me
.REG
[2])(fra
.me
.REG
[2], NIT_NULL
);
290 REGB0
= TAG_Bool(!UNTAG_Bool(REGB0
));
293 stack_frame_head
= fra
.me
.prev
;
296 static const char LOCATE_standard___collection___list___List___has_only
[] = "list::List::(abstract_collection::Collection::has_only)";
297 val_t
standard___collection___list___List___has_only(val_t p0
, val_t p1
){
298 struct {struct stack_frame_t me
; val_t MORE_REG
[2];} fra
;
302 fra
.me
.prev
= stack_frame_head
; stack_frame_head
= &fra
.me
;
303 fra
.me
.file
= LOCATE_standard___collection___list
;
305 fra
.me
.meth
= LOCATE_standard___collection___list___List___has_only
;
306 fra
.me
.has_broke
= 0;
308 fra
.me
.nitni_local_ref_head
= NULL
;
309 fra
.me
.REG
[0] = NIT_NULL
;
310 fra
.me
.REG
[1] = NIT_NULL
;
311 fra
.me
.REG
[2] = NIT_NULL
;
314 /* ../lib/standard/collection/list.nit:60 */
315 fra
.me
.REG
[0] = ATTR_standard___collection___list___List____head(fra
.me
.REG
[0]);
316 /* ../lib/standard/collection/list.nit:61 */
318 REGB0
= TAG_Bool(fra
.me
.REG
[0]==NIT_NULL
);
319 if (UNTAG_Bool(REGB0
)) {
321 REGB1
= TAG_Bool(fra
.me
.REG
[0]==NIT_NULL
);
322 if (UNTAG_Bool(REGB1
)) {
326 REGB1
= CALL_standard___kernel___Object_____eqeq(fra
.me
.REG
[0])(fra
.me
.REG
[0], NIT_NULL
);
330 REGB0
= TAG_Bool(!UNTAG_Bool(REGB0
));
331 if (UNTAG_Bool(REGB0
)) {
332 /* ../lib/standard/collection/list.nit:62 */
333 REGB0
= TAG_Bool(fra
.me
.REG
[0]==NIT_NULL
);
334 if (UNTAG_Bool(REGB0
)) {
335 nit_abort("Reciever is null", NULL
, LOCATE_standard___collection___list
, 62);
337 fra
.me
.REG
[2] = CALL_standard___collection___abstract_collection___Container___item(fra
.me
.REG
[0])(fra
.me
.REG
[0]);
338 REGB0
= TAG_Bool(IS_EQUAL_NN(fra
.me
.REG
[2],fra
.me
.REG
[1]));
339 if (UNTAG_Bool(REGB0
)) {
341 REGB1
= TAG_Bool(fra
.me
.REG
[2]==NIT_NULL
);
342 if (UNTAG_Bool(REGB1
)) {
346 REGB1
= CALL_standard___kernel___Object_____eqeq(fra
.me
.REG
[2])(fra
.me
.REG
[2], fra
.me
.REG
[1]);
350 REGB0
= TAG_Bool(!UNTAG_Bool(REGB0
));
351 if (UNTAG_Bool(REGB0
)) {
355 /* ../lib/standard/collection/list.nit:63 */
356 REGB1
= TAG_Bool(fra
.me
.REG
[0]==NIT_NULL
);
357 if (UNTAG_Bool(REGB1
)) {
358 nit_abort("Reciever is null", NULL
, LOCATE_standard___collection___list
, 63);
360 fra
.me
.REG
[2] = CALL_standard___collection___list___ListNode___next(fra
.me
.REG
[0])(fra
.me
.REG
[0]);
361 fra
.me
.REG
[0] = fra
.me
.REG
[2];
363 /* ../lib/standard/collection/list.nit:61 */
368 /* ../lib/standard/collection/list.nit:65 */
373 stack_frame_head
= fra
.me
.prev
;
376 static const char LOCATE_standard___collection___list___List___count
[] = "list::List::(abstract_collection::Collection::count)";
377 val_t
standard___collection___list___List___count(val_t p0
, val_t p1
){
378 struct {struct stack_frame_t me
; val_t MORE_REG
[2];} fra
;
383 fra
.me
.prev
= stack_frame_head
; stack_frame_head
= &fra
.me
;
384 fra
.me
.file
= LOCATE_standard___collection___list
;
386 fra
.me
.meth
= LOCATE_standard___collection___list___List___count
;
387 fra
.me
.has_broke
= 0;
389 fra
.me
.nitni_local_ref_head
= NULL
;
390 fra
.me
.REG
[0] = NIT_NULL
;
391 fra
.me
.REG
[1] = NIT_NULL
;
392 fra
.me
.REG
[2] = NIT_NULL
;
395 /* ../lib/standard/collection/list.nit:70 */
397 /* ../lib/standard/collection/list.nit:71 */
398 fra
.me
.REG
[0] = ATTR_standard___collection___list___List____head(fra
.me
.REG
[0]);
399 /* ../lib/standard/collection/list.nit:72 */
401 REGB1
= TAG_Bool(fra
.me
.REG
[0]==NIT_NULL
);
402 if (UNTAG_Bool(REGB1
)) {
404 REGB2
= TAG_Bool(fra
.me
.REG
[0]==NIT_NULL
);
405 if (UNTAG_Bool(REGB2
)) {
409 REGB2
= CALL_standard___kernel___Object_____eqeq(fra
.me
.REG
[0])(fra
.me
.REG
[0], NIT_NULL
);
413 REGB1
= TAG_Bool(!UNTAG_Bool(REGB1
));
414 if (UNTAG_Bool(REGB1
)) {
415 /* ../lib/standard/collection/list.nit:73 */
416 REGB1
= TAG_Bool(fra
.me
.REG
[0]==NIT_NULL
);
417 if (UNTAG_Bool(REGB1
)) {
418 nit_abort("Reciever is null", NULL
, LOCATE_standard___collection___list
, 73);
420 fra
.me
.REG
[2] = CALL_standard___collection___abstract_collection___Container___item(fra
.me
.REG
[0])(fra
.me
.REG
[0]);
421 REGB1
= TAG_Bool(IS_EQUAL_NN(fra
.me
.REG
[2],fra
.me
.REG
[1]));
422 if (UNTAG_Bool(REGB1
)) {
424 REGB2
= TAG_Bool(fra
.me
.REG
[2]==NIT_NULL
);
425 if (UNTAG_Bool(REGB2
)) {
429 REGB2
= CALL_standard___kernel___Object_____eqeq(fra
.me
.REG
[2])(fra
.me
.REG
[2], fra
.me
.REG
[1]);
433 REGB1
= TAG_Bool(!UNTAG_Bool(REGB1
));
434 if (UNTAG_Bool(REGB1
)) {
436 /* ../lib/standard/kernel.nit:238 */
437 REGB1
= TAG_Int(UNTAG_Int(REGB0
)+UNTAG_Int(REGB1
));
438 /* ../lib/standard/collection/list.nit:73 */
441 /* ../lib/standard/collection/list.nit:74 */
442 REGB1
= TAG_Bool(fra
.me
.REG
[0]==NIT_NULL
);
443 if (UNTAG_Bool(REGB1
)) {
444 nit_abort("Reciever is null", NULL
, LOCATE_standard___collection___list
, 74);
446 fra
.me
.REG
[2] = CALL_standard___collection___list___ListNode___next(fra
.me
.REG
[0])(fra
.me
.REG
[0]);
447 fra
.me
.REG
[0] = fra
.me
.REG
[2];
449 /* ../lib/standard/collection/list.nit:72 */
454 /* ../lib/standard/collection/list.nit:76 */
457 stack_frame_head
= fra
.me
.prev
;
460 static const char LOCATE_standard___collection___list___List___slice
[] = "list::List::slice";
461 val_t
standard___collection___list___List___slice(val_t p0
, val_t p1
, val_t p2
){
462 struct {struct stack_frame_t me
; val_t MORE_REG
[2];} fra
;
468 fra
.me
.prev
= stack_frame_head
; stack_frame_head
= &fra
.me
;
469 fra
.me
.file
= LOCATE_standard___collection___list
;
471 fra
.me
.meth
= LOCATE_standard___collection___list___List___slice
;
472 fra
.me
.has_broke
= 0;
474 fra
.me
.nitni_local_ref_head
= NULL
;
475 fra
.me
.REG
[0] = NIT_NULL
;
476 fra
.me
.REG
[1] = NIT_NULL
;
477 fra
.me
.REG
[2] = NIT_NULL
;
481 /* ../lib/standard/collection/list.nit:81 */
483 REGB3
= TAG_Bool(VAL_ISA(REGB2
, VTCOLOR_standard___kernel___Comparable___OTHER(REGB0
), VTID_standard___kernel___Comparable___OTHER(REGB0
))) /*cast OTHER*/;
484 if (UNTAG_Bool(REGB3
)) {
486 nit_abort("Cast failed", NULL
, LOCATE_standard___kernel
, 0);
488 /* ../lib/standard/kernel.nit:236 */
489 REGB2
= TAG_Bool(UNTAG_Int(REGB0
)>=UNTAG_Int(REGB2
));
490 /* ../lib/standard/collection/list.nit:81 */
491 if (UNTAG_Bool(REGB2
)) {
492 REGB2
= CALL_standard___collection___abstract_collection___Collection___length(fra
.me
.REG
[0])(fra
.me
.REG
[0]);
493 REGB3
= TAG_Bool(VAL_ISA(REGB2
, VTCOLOR_standard___kernel___Comparable___OTHER(REGB0
), VTID_standard___kernel___Comparable___OTHER(REGB0
))) /*cast OTHER*/;
494 if (UNTAG_Bool(REGB3
)) {
496 nit_abort("Cast failed", NULL
, LOCATE_standard___kernel
, 0);
498 /* ../lib/standard/kernel.nit:235 */
499 REGB2
= TAG_Bool(UNTAG_Int(REGB0
)<UNTAG_Int(REGB2
));
501 /* ../lib/standard/collection/list.nit:81 */
505 if (UNTAG_Bool(REGB2
)) {
507 nit_abort("Assert failed", NULL
, LOCATE_standard___collection___list
, 81);
509 /* ../lib/standard/collection/list.nit:82 */
511 REGB3
= TAG_Bool(VAL_ISA(REGB2
, VTCOLOR_standard___kernel___Comparable___OTHER(REGB1
), VTID_standard___kernel___Comparable___OTHER(REGB1
))) /*cast OTHER*/;
512 if (UNTAG_Bool(REGB3
)) {
514 nit_abort("Cast failed", NULL
, LOCATE_standard___kernel
, 0);
516 /* ../lib/standard/kernel.nit:236 */
517 REGB2
= TAG_Bool(UNTAG_Int(REGB1
)>=UNTAG_Int(REGB2
));
518 /* ../lib/standard/collection/list.nit:82 */
519 if (UNTAG_Bool(REGB2
)) {
520 REGB2
= CALL_standard___collection___abstract_collection___Collection___length(fra
.me
.REG
[0])(fra
.me
.REG
[0]);
521 REGB3
= TAG_Bool(VAL_ISA(REGB2
, VTCOLOR_standard___kernel___Comparable___OTHER(REGB1
), VTID_standard___kernel___Comparable___OTHER(REGB1
))) /*cast OTHER*/;
522 if (UNTAG_Bool(REGB3
)) {
524 nit_abort("Cast failed", NULL
, LOCATE_standard___kernel
, 0);
526 /* ../lib/standard/kernel.nit:235 */
527 REGB2
= TAG_Bool(UNTAG_Int(REGB1
)<UNTAG_Int(REGB2
));
529 /* ../lib/standard/collection/list.nit:82 */
533 if (UNTAG_Bool(REGB2
)) {
534 REGB2
= TAG_Bool(VAL_ISA(REGB1
, VTCOLOR_standard___kernel___Comparable___OTHER(REGB0
), VTID_standard___kernel___Comparable___OTHER(REGB0
))) /*cast OTHER*/;
535 if (UNTAG_Bool(REGB2
)) {
537 nit_abort("Cast failed", NULL
, LOCATE_standard___kernel
, 0);
539 /* ../lib/standard/kernel.nit:234 */
540 REGB2
= TAG_Bool(UNTAG_Int(REGB0
)<=UNTAG_Int(REGB1
));
542 /* ../lib/standard/collection/list.nit:82 */
546 if (UNTAG_Bool(REGB2
)) {
548 nit_abort("Assert failed", NULL
, LOCATE_standard___collection___list
, 82);
550 /* ../lib/standard/collection/list.nit:83 */
551 fra
.me
.REG
[1] = NEW_List_standard___collection___list___List___init();
552 /* ../lib/standard/collection/list.nit:84 */
554 REGB2
= TAG_Bool(VAL_ISA(REGB1
, VTCOLOR_standard___kernel___Comparable___OTHER(REGB0
), VTID_standard___kernel___Comparable___OTHER(REGB0
))) /*cast OTHER*/;
555 if (UNTAG_Bool(REGB2
)) {
557 nit_abort("Cast failed", NULL
, LOCATE_standard___kernel
, 0);
559 /* ../lib/standard/kernel.nit:234 */
560 REGB2
= TAG_Bool(UNTAG_Int(REGB0
)<=UNTAG_Int(REGB1
));
561 /* ../lib/standard/collection/list.nit:84 */
562 if (UNTAG_Bool(REGB2
)) {
563 /* ../lib/standard/collection/list.nit:85 */
564 fra
.me
.REG
[2] = CALL_standard___collection___abstract_collection___SequenceRead_____bra(fra
.me
.REG
[0])(fra
.me
.REG
[0], REGB0
);
565 CALL_standard___collection___abstract_collection___SimpleCollection___add(fra
.me
.REG
[1])(fra
.me
.REG
[1], fra
.me
.REG
[2]);
566 /* ../lib/standard/collection/list.nit:86 */
568 /* ../lib/standard/kernel.nit:238 */
569 REGB2
= TAG_Int(UNTAG_Int(REGB0
)+UNTAG_Int(REGB2
));
570 /* ../lib/standard/collection/list.nit:86 */
573 /* ../lib/standard/collection/list.nit:84 */
578 /* ../lib/standard/collection/list.nit:88 */
581 stack_frame_head
= fra
.me
.prev
;
582 return fra
.me
.REG
[1];
584 static const char LOCATE_standard___collection___list___List___push
[] = "list::List::(abstract_collection::Sequence::push)";
585 void standard___collection___list___List___push(val_t p0
, val_t p1
){
586 struct {struct stack_frame_t me
; val_t MORE_REG
[2];} fra
;
590 fra
.me
.prev
= stack_frame_head
; stack_frame_head
= &fra
.me
;
591 fra
.me
.file
= LOCATE_standard___collection___list
;
593 fra
.me
.meth
= LOCATE_standard___collection___list___List___push
;
594 fra
.me
.has_broke
= 0;
596 fra
.me
.nitni_local_ref_head
= NULL
;
597 fra
.me
.REG
[0] = NIT_NULL
;
598 fra
.me
.REG
[1] = NIT_NULL
;
599 fra
.me
.REG
[2] = NIT_NULL
;
602 /* ../lib/standard/collection/list.nit:96 */
603 fra
.me
.REG
[1] = NEW_ListNode_standard___collection___list___ListNode___init(fra
.me
.REG
[1]);
604 /* ../lib/standard/collection/list.nit:97 */
605 fra
.me
.REG
[2] = ATTR_standard___collection___list___List____tail(fra
.me
.REG
[0]);
606 REGB0
= TAG_Bool(fra
.me
.REG
[2]==NIT_NULL
);
607 if (UNTAG_Bool(REGB0
)) {
609 REGB1
= TAG_Bool(fra
.me
.REG
[2]==NIT_NULL
);
610 if (UNTAG_Bool(REGB1
)) {
614 REGB1
= CALL_standard___kernel___Object_____eqeq(fra
.me
.REG
[2])(fra
.me
.REG
[2], NIT_NULL
);
618 if (UNTAG_Bool(REGB0
)) {
619 /* ../lib/standard/collection/list.nit:98 */
620 ATTR_standard___collection___list___List____head(fra
.me
.REG
[0]) = fra
.me
.REG
[1];
622 /* ../lib/standard/collection/list.nit:100 */
623 fra
.me
.REG
[2] = ATTR_standard___collection___list___List____tail(fra
.me
.REG
[0]);
624 REGB0
= TAG_Bool(fra
.me
.REG
[2]==NIT_NULL
);
625 if (UNTAG_Bool(REGB0
)) {
626 nit_abort("Reciever is null", NULL
, LOCATE_standard___collection___list
, 100);
628 CALL_standard___collection___list___ListNode___next__eq(fra
.me
.REG
[2])(fra
.me
.REG
[2], fra
.me
.REG
[1]);
629 /* ../lib/standard/collection/list.nit:101 */
630 fra
.me
.REG
[2] = ATTR_standard___collection___list___List____tail(fra
.me
.REG
[0]);
631 CALL_standard___collection___list___ListNode___prev__eq(fra
.me
.REG
[1])(fra
.me
.REG
[1], fra
.me
.REG
[2]);
633 /* ../lib/standard/collection/list.nit:103 */
634 ATTR_standard___collection___list___List____tail(fra
.me
.REG
[0]) = fra
.me
.REG
[1];
635 stack_frame_head
= fra
.me
.prev
;
638 static const char LOCATE_standard___collection___list___List___unshift
[] = "list::List::(abstract_collection::Sequence::unshift)";
639 void standard___collection___list___List___unshift(val_t p0
, val_t p1
){
640 struct {struct stack_frame_t me
; val_t MORE_REG
[2];} fra
;
644 fra
.me
.prev
= stack_frame_head
; stack_frame_head
= &fra
.me
;
645 fra
.me
.file
= LOCATE_standard___collection___list
;
647 fra
.me
.meth
= LOCATE_standard___collection___list___List___unshift
;
648 fra
.me
.has_broke
= 0;
650 fra
.me
.nitni_local_ref_head
= NULL
;
651 fra
.me
.REG
[0] = NIT_NULL
;
652 fra
.me
.REG
[1] = NIT_NULL
;
653 fra
.me
.REG
[2] = NIT_NULL
;
656 /* ../lib/standard/collection/list.nit:109 */
657 fra
.me
.REG
[1] = NEW_ListNode_standard___collection___list___ListNode___init(fra
.me
.REG
[1]);
658 /* ../lib/standard/collection/list.nit:110 */
659 fra
.me
.REG
[2] = ATTR_standard___collection___list___List____head(fra
.me
.REG
[0]);
660 REGB0
= TAG_Bool(fra
.me
.REG
[2]==NIT_NULL
);
661 if (UNTAG_Bool(REGB0
)) {
663 REGB1
= TAG_Bool(fra
.me
.REG
[2]==NIT_NULL
);
664 if (UNTAG_Bool(REGB1
)) {
668 REGB1
= CALL_standard___kernel___Object_____eqeq(fra
.me
.REG
[2])(fra
.me
.REG
[2], NIT_NULL
);
672 if (UNTAG_Bool(REGB0
)) {
673 /* ../lib/standard/collection/list.nit:111 */
674 ATTR_standard___collection___list___List____tail(fra
.me
.REG
[0]) = fra
.me
.REG
[1];
676 /* ../lib/standard/collection/list.nit:113 */
677 fra
.me
.REG
[2] = ATTR_standard___collection___list___List____head(fra
.me
.REG
[0]);
678 CALL_standard___collection___list___ListNode___next__eq(fra
.me
.REG
[1])(fra
.me
.REG
[1], fra
.me
.REG
[2]);
679 /* ../lib/standard/collection/list.nit:114 */
680 fra
.me
.REG
[2] = ATTR_standard___collection___list___List____head(fra
.me
.REG
[0]);
681 REGB0
= TAG_Bool(fra
.me
.REG
[2]==NIT_NULL
);
682 if (UNTAG_Bool(REGB0
)) {
683 nit_abort("Reciever is null", NULL
, LOCATE_standard___collection___list
, 114);
685 CALL_standard___collection___list___ListNode___prev__eq(fra
.me
.REG
[2])(fra
.me
.REG
[2], fra
.me
.REG
[1]);
687 /* ../lib/standard/collection/list.nit:116 */
688 ATTR_standard___collection___list___List____head(fra
.me
.REG
[0]) = fra
.me
.REG
[1];
689 stack_frame_head
= fra
.me
.prev
;
692 static const char LOCATE_standard___collection___list___List___link
[] = "list::List::link";
693 void standard___collection___list___List___link(val_t p0
, val_t p1
){
694 struct {struct stack_frame_t me
; val_t MORE_REG
[3];} fra
;
698 fra
.me
.prev
= stack_frame_head
; stack_frame_head
= &fra
.me
;
699 fra
.me
.file
= LOCATE_standard___collection___list
;
701 fra
.me
.meth
= LOCATE_standard___collection___list___List___link
;
702 fra
.me
.has_broke
= 0;
704 fra
.me
.nitni_local_ref_head
= NULL
;
705 fra
.me
.REG
[0] = NIT_NULL
;
706 fra
.me
.REG
[1] = NIT_NULL
;
707 fra
.me
.REG
[2] = NIT_NULL
;
708 fra
.me
.REG
[3] = NIT_NULL
;
711 /* ../lib/standard/collection/list.nit:124 */
712 fra
.me
.REG
[2] = ATTR_standard___collection___list___List____tail(fra
.me
.REG
[0]);
713 REGB0
= TAG_Bool(fra
.me
.REG
[2]==NIT_NULL
);
714 if (UNTAG_Bool(REGB0
)) {
716 REGB1
= TAG_Bool(fra
.me
.REG
[2]==NIT_NULL
);
717 if (UNTAG_Bool(REGB1
)) {
721 REGB1
= CALL_standard___kernel___Object_____eqeq(fra
.me
.REG
[2])(fra
.me
.REG
[2], NIT_NULL
);
725 if (UNTAG_Bool(REGB0
)) {
726 /* ../lib/standard/collection/list.nit:125 */
727 fra
.me
.REG
[2] = ATTR_standard___collection___list___List____head(fra
.me
.REG
[1]);
728 ATTR_standard___collection___list___List____head(fra
.me
.REG
[0]) = fra
.me
.REG
[2];
730 /* ../lib/standard/collection/list.nit:126 */
731 fra
.me
.REG
[2] = ATTR_standard___collection___list___List____head(fra
.me
.REG
[1]);
732 REGB0
= TAG_Bool(fra
.me
.REG
[2]==NIT_NULL
);
733 if (UNTAG_Bool(REGB0
)) {
735 REGB1
= TAG_Bool(fra
.me
.REG
[2]==NIT_NULL
);
736 if (UNTAG_Bool(REGB1
)) {
740 REGB1
= CALL_standard___kernel___Object_____eqeq(fra
.me
.REG
[2])(fra
.me
.REG
[2], NIT_NULL
);
744 REGB0
= TAG_Bool(!UNTAG_Bool(REGB0
));
745 if (UNTAG_Bool(REGB0
)) {
746 /* ../lib/standard/collection/list.nit:127 */
747 fra
.me
.REG
[2] = ATTR_standard___collection___list___List____tail(fra
.me
.REG
[0]);
748 fra
.me
.REG
[3] = ATTR_standard___collection___list___List____head(fra
.me
.REG
[1]);
749 REGB0
= TAG_Bool(fra
.me
.REG
[2]==NIT_NULL
);
750 if (UNTAG_Bool(REGB0
)) {
751 nit_abort("Reciever is null", NULL
, LOCATE_standard___collection___list
, 127);
753 CALL_standard___collection___list___ListNode___next__eq(fra
.me
.REG
[2])(fra
.me
.REG
[2], fra
.me
.REG
[3]);
754 /* ../lib/standard/collection/list.nit:128 */
755 fra
.me
.REG
[3] = ATTR_standard___collection___list___List____tail(fra
.me
.REG
[0]);
756 REGB0
= TAG_Bool(fra
.me
.REG
[3]==NIT_NULL
);
757 if (UNTAG_Bool(REGB0
)) {
758 nit_abort("Reciever is null", NULL
, LOCATE_standard___collection___list
, 128);
760 fra
.me
.REG
[3] = CALL_standard___collection___list___ListNode___next(fra
.me
.REG
[3])(fra
.me
.REG
[3]);
761 fra
.me
.REG
[2] = ATTR_standard___collection___list___List____tail(fra
.me
.REG
[0]);
762 REGB0
= TAG_Bool(fra
.me
.REG
[3]==NIT_NULL
);
763 if (UNTAG_Bool(REGB0
)) {
764 nit_abort("Reciever is null", NULL
, LOCATE_standard___collection___list
, 128);
766 CALL_standard___collection___list___ListNode___prev__eq(fra
.me
.REG
[3])(fra
.me
.REG
[3], fra
.me
.REG
[2]);
769 /* ../lib/standard/collection/list.nit:130 */
770 fra
.me
.REG
[2] = ATTR_standard___collection___list___List____tail(fra
.me
.REG
[1]);
771 ATTR_standard___collection___list___List____tail(fra
.me
.REG
[0]) = fra
.me
.REG
[2];
772 /* ../lib/standard/collection/list.nit:131 */
773 CALL_standard___collection___abstract_collection___RemovableCollection___clear(fra
.me
.REG
[1])(fra
.me
.REG
[1]);
774 stack_frame_head
= fra
.me
.prev
;
777 static const char LOCATE_standard___collection___list___List___pop
[] = "list::List::(abstract_collection::Sequence::pop)";
778 val_t
standard___collection___list___List___pop(val_t p0
){
779 struct {struct stack_frame_t me
; val_t MORE_REG
[2];} fra
;
783 fra
.me
.prev
= stack_frame_head
; stack_frame_head
= &fra
.me
;
784 fra
.me
.file
= LOCATE_standard___collection___list
;
786 fra
.me
.meth
= LOCATE_standard___collection___list___List___pop
;
787 fra
.me
.has_broke
= 0;
789 fra
.me
.nitni_local_ref_head
= NULL
;
790 fra
.me
.REG
[0] = NIT_NULL
;
791 fra
.me
.REG
[1] = NIT_NULL
;
792 fra
.me
.REG
[2] = NIT_NULL
;
794 /* ../lib/standard/collection/list.nit:139 */
795 fra
.me
.REG
[1] = ATTR_standard___collection___list___List____tail(fra
.me
.REG
[0]);
796 /* ../lib/standard/collection/list.nit:140 */
797 REGB0
= TAG_Bool(fra
.me
.REG
[1]==NIT_NULL
);
798 if (UNTAG_Bool(REGB0
)) {
799 nit_abort("Reciever is null", NULL
, LOCATE_standard___collection___list
, 140);
801 fra
.me
.REG
[2] = CALL_standard___collection___list___ListNode___prev(fra
.me
.REG
[1])(fra
.me
.REG
[1]);
802 ATTR_standard___collection___list___List____tail(fra
.me
.REG
[0]) = fra
.me
.REG
[2];
803 /* ../lib/standard/collection/list.nit:141 */
804 REGB0
= TAG_Bool(fra
.me
.REG
[1]==NIT_NULL
);
805 if (UNTAG_Bool(REGB0
)) {
806 nit_abort("Reciever is null", NULL
, LOCATE_standard___collection___list
, 141);
808 CALL_standard___collection___list___ListNode___prev__eq(fra
.me
.REG
[1])(fra
.me
.REG
[1], NIT_NULL
);
809 /* ../lib/standard/collection/list.nit:142 */
810 fra
.me
.REG
[2] = ATTR_standard___collection___list___List____tail(fra
.me
.REG
[0]);
811 REGB0
= TAG_Bool(fra
.me
.REG
[2]==NIT_NULL
);
812 if (UNTAG_Bool(REGB0
)) {
814 REGB1
= TAG_Bool(fra
.me
.REG
[2]==NIT_NULL
);
815 if (UNTAG_Bool(REGB1
)) {
819 REGB1
= CALL_standard___kernel___Object_____eqeq(fra
.me
.REG
[2])(fra
.me
.REG
[2], NIT_NULL
);
823 if (UNTAG_Bool(REGB0
)) {
824 /* ../lib/standard/collection/list.nit:143 */
825 ATTR_standard___collection___list___List____head(fra
.me
.REG
[0]) = NIT_NULL
;
827 /* ../lib/standard/collection/list.nit:145 */
828 fra
.me
.REG
[0] = ATTR_standard___collection___list___List____tail(fra
.me
.REG
[0]);
829 REGB0
= TAG_Bool(fra
.me
.REG
[0]==NIT_NULL
);
830 if (UNTAG_Bool(REGB0
)) {
831 nit_abort("Reciever is null", NULL
, LOCATE_standard___collection___list
, 145);
833 CALL_standard___collection___list___ListNode___next__eq(fra
.me
.REG
[0])(fra
.me
.REG
[0], NIT_NULL
);
835 /* ../lib/standard/collection/list.nit:147 */
836 REGB0
= TAG_Bool(fra
.me
.REG
[1]==NIT_NULL
);
837 if (UNTAG_Bool(REGB0
)) {
838 nit_abort("Reciever is null", NULL
, LOCATE_standard___collection___list
, 147);
840 fra
.me
.REG
[1] = CALL_standard___collection___abstract_collection___Container___item(fra
.me
.REG
[1])(fra
.me
.REG
[1]);
843 stack_frame_head
= fra
.me
.prev
;
844 return fra
.me
.REG
[1];
846 static const char LOCATE_standard___collection___list___List___shift
[] = "list::List::(abstract_collection::Sequence::shift)";
847 val_t
standard___collection___list___List___shift(val_t p0
){
848 struct {struct stack_frame_t me
; val_t MORE_REG
[2];} fra
;
852 fra
.me
.prev
= stack_frame_head
; stack_frame_head
= &fra
.me
;
853 fra
.me
.file
= LOCATE_standard___collection___list
;
855 fra
.me
.meth
= LOCATE_standard___collection___list___List___shift
;
856 fra
.me
.has_broke
= 0;
858 fra
.me
.nitni_local_ref_head
= NULL
;
859 fra
.me
.REG
[0] = NIT_NULL
;
860 fra
.me
.REG
[1] = NIT_NULL
;
861 fra
.me
.REG
[2] = NIT_NULL
;
863 /* ../lib/standard/collection/list.nit:153 */
864 fra
.me
.REG
[1] = ATTR_standard___collection___list___List____head(fra
.me
.REG
[0]);
865 /* ../lib/standard/collection/list.nit:154 */
866 REGB0
= TAG_Bool(fra
.me
.REG
[1]==NIT_NULL
);
867 if (UNTAG_Bool(REGB0
)) {
868 nit_abort("Reciever is null", NULL
, LOCATE_standard___collection___list
, 154);
870 fra
.me
.REG
[2] = CALL_standard___collection___list___ListNode___next(fra
.me
.REG
[1])(fra
.me
.REG
[1]);
871 ATTR_standard___collection___list___List____head(fra
.me
.REG
[0]) = fra
.me
.REG
[2];
872 /* ../lib/standard/collection/list.nit:155 */
873 REGB0
= TAG_Bool(fra
.me
.REG
[1]==NIT_NULL
);
874 if (UNTAG_Bool(REGB0
)) {
875 nit_abort("Reciever is null", NULL
, LOCATE_standard___collection___list
, 155);
877 CALL_standard___collection___list___ListNode___next__eq(fra
.me
.REG
[1])(fra
.me
.REG
[1], NIT_NULL
);
878 /* ../lib/standard/collection/list.nit:156 */
879 fra
.me
.REG
[2] = ATTR_standard___collection___list___List____head(fra
.me
.REG
[0]);
880 REGB0
= TAG_Bool(fra
.me
.REG
[2]==NIT_NULL
);
881 if (UNTAG_Bool(REGB0
)) {
883 REGB1
= TAG_Bool(fra
.me
.REG
[2]==NIT_NULL
);
884 if (UNTAG_Bool(REGB1
)) {
888 REGB1
= CALL_standard___kernel___Object_____eqeq(fra
.me
.REG
[2])(fra
.me
.REG
[2], NIT_NULL
);
892 if (UNTAG_Bool(REGB0
)) {
893 /* ../lib/standard/collection/list.nit:157 */
894 ATTR_standard___collection___list___List____tail(fra
.me
.REG
[0]) = NIT_NULL
;
896 /* ../lib/standard/collection/list.nit:159 */
897 fra
.me
.REG
[0] = ATTR_standard___collection___list___List____head(fra
.me
.REG
[0]);
898 REGB0
= TAG_Bool(fra
.me
.REG
[0]==NIT_NULL
);
899 if (UNTAG_Bool(REGB0
)) {
900 nit_abort("Reciever is null", NULL
, LOCATE_standard___collection___list
, 159);
902 CALL_standard___collection___list___ListNode___prev__eq(fra
.me
.REG
[0])(fra
.me
.REG
[0], NIT_NULL
);
904 /* ../lib/standard/collection/list.nit:161 */
905 REGB0
= TAG_Bool(fra
.me
.REG
[1]==NIT_NULL
);
906 if (UNTAG_Bool(REGB0
)) {
907 nit_abort("Reciever is null", NULL
, LOCATE_standard___collection___list
, 161);
909 fra
.me
.REG
[1] = CALL_standard___collection___abstract_collection___Container___item(fra
.me
.REG
[1])(fra
.me
.REG
[1]);
912 stack_frame_head
= fra
.me
.prev
;
913 return fra
.me
.REG
[1];
915 static const char LOCATE_standard___collection___list___List___remove
[] = "list::List::(abstract_collection::RemovableCollection::remove)";
916 void standard___collection___list___List___remove(val_t p0
, val_t p1
){
917 struct {struct stack_frame_t me
; val_t MORE_REG
[2];} fra
;
921 fra
.me
.prev
= stack_frame_head
; stack_frame_head
= &fra
.me
;
922 fra
.me
.file
= LOCATE_standard___collection___list
;
924 fra
.me
.meth
= LOCATE_standard___collection___list___List___remove
;
925 fra
.me
.has_broke
= 0;
927 fra
.me
.nitni_local_ref_head
= NULL
;
928 fra
.me
.REG
[0] = NIT_NULL
;
929 fra
.me
.REG
[1] = NIT_NULL
;
930 fra
.me
.REG
[2] = NIT_NULL
;
933 /* ../lib/standard/collection/list.nit:166 */
934 fra
.me
.REG
[2] = ATTR_standard___collection___list___List____head(fra
.me
.REG
[0]);
935 fra
.me
.REG
[2] = CALL_standard___collection___list___List___search_node_after(fra
.me
.REG
[0])(fra
.me
.REG
[0], fra
.me
.REG
[1], fra
.me
.REG
[2]);
936 /* ../lib/standard/collection/list.nit:167 */
937 REGB0
= TAG_Bool(fra
.me
.REG
[2]==NIT_NULL
);
938 if (UNTAG_Bool(REGB0
)) {
940 REGB1
= TAG_Bool(fra
.me
.REG
[2]==NIT_NULL
);
941 if (UNTAG_Bool(REGB1
)) {
945 REGB1
= CALL_standard___kernel___Object_____eqeq(fra
.me
.REG
[2])(fra
.me
.REG
[2], NIT_NULL
);
949 REGB0
= TAG_Bool(!UNTAG_Bool(REGB0
));
950 if (UNTAG_Bool(REGB0
)) {
951 CALL_standard___collection___list___List___remove_node(fra
.me
.REG
[0])(fra
.me
.REG
[0], fra
.me
.REG
[2]);
953 stack_frame_head
= fra
.me
.prev
;
956 static const char LOCATE_standard___collection___list___List___remove_at
[] = "list::List::(abstract_collection::Sequence::remove_at)";
957 void standard___collection___list___List___remove_at(val_t p0
, val_t p1
){
958 struct {struct stack_frame_t me
; val_t MORE_REG
[1];} fra
;
962 fra
.me
.prev
= stack_frame_head
; stack_frame_head
= &fra
.me
;
963 fra
.me
.file
= LOCATE_standard___collection___list
;
965 fra
.me
.meth
= LOCATE_standard___collection___list___List___remove_at
;
966 fra
.me
.has_broke
= 0;
968 fra
.me
.nitni_local_ref_head
= NULL
;
969 fra
.me
.REG
[0] = NIT_NULL
;
970 fra
.me
.REG
[1] = NIT_NULL
;
973 /* ../lib/standard/collection/list.nit:172 */
974 fra
.me
.REG
[1] = CALL_standard___collection___list___List___get_node(fra
.me
.REG
[0])(fra
.me
.REG
[0], REGB0
);
975 /* ../lib/standard/collection/list.nit:173 */
976 REGB0
= TAG_Bool(fra
.me
.REG
[1]==NIT_NULL
);
977 if (UNTAG_Bool(REGB0
)) {
979 REGB1
= TAG_Bool(fra
.me
.REG
[1]==NIT_NULL
);
980 if (UNTAG_Bool(REGB1
)) {
984 REGB1
= CALL_standard___kernel___Object_____eqeq(fra
.me
.REG
[1])(fra
.me
.REG
[1], NIT_NULL
);
988 REGB0
= TAG_Bool(!UNTAG_Bool(REGB0
));
989 if (UNTAG_Bool(REGB0
)) {
990 CALL_standard___collection___list___List___remove_node(fra
.me
.REG
[0])(fra
.me
.REG
[0], fra
.me
.REG
[1]);
992 stack_frame_head
= fra
.me
.prev
;
995 static const char LOCATE_standard___collection___list___List___clear
[] = "list::List::(abstract_collection::RemovableCollection::clear)";
996 void standard___collection___list___List___clear(val_t p0
){
997 struct {struct stack_frame_t me
;} fra
;
999 fra
.me
.prev
= stack_frame_head
; stack_frame_head
= &fra
.me
;
1000 fra
.me
.file
= LOCATE_standard___collection___list
;
1002 fra
.me
.meth
= LOCATE_standard___collection___list___List___clear
;
1003 fra
.me
.has_broke
= 0;
1004 fra
.me
.REG_size
= 1;
1005 fra
.me
.nitni_local_ref_head
= NULL
;
1006 fra
.me
.REG
[0] = NIT_NULL
;
1008 /* ../lib/standard/collection/list.nit:178 */
1009 ATTR_standard___collection___list___List____head(fra
.me
.REG
[0]) = NIT_NULL
;
1010 /* ../lib/standard/collection/list.nit:179 */
1011 ATTR_standard___collection___list___List____tail(fra
.me
.REG
[0]) = NIT_NULL
;
1012 stack_frame_head
= fra
.me
.prev
;
1015 static const char LOCATE_standard___collection___list___List___iterator
[] = "list::List::(abstract_collection::Collection::iterator)";
1016 val_t
standard___collection___list___List___iterator(val_t p0
){
1017 struct {struct stack_frame_t me
;} fra
;
1019 fra
.me
.prev
= stack_frame_head
; stack_frame_head
= &fra
.me
;
1020 fra
.me
.file
= LOCATE_standard___collection___list
;
1022 fra
.me
.meth
= LOCATE_standard___collection___list___List___iterator
;
1023 fra
.me
.has_broke
= 0;
1024 fra
.me
.REG_size
= 1;
1025 fra
.me
.nitni_local_ref_head
= NULL
;
1026 fra
.me
.REG
[0] = NIT_NULL
;
1028 /* ../lib/standard/collection/list.nit:183 */
1029 fra
.me
.REG
[0] = NEW_ListIterator_standard___collection___list___ListIterator___init(fra
.me
.REG
[0]);
1032 stack_frame_head
= fra
.me
.prev
;
1033 return fra
.me
.REG
[0];
1035 static const char LOCATE_standard___collection___list___List___init
[] = "list::List::init";
1036 void standard___collection___list___List___init(val_t p0
, int* init_table
){
1037 int itpos0
= VAL2OBJ(p0
)->vft
[INIT_TABLE_POS_standard___collection___list___List
].i
;
1038 struct {struct stack_frame_t me
;} fra
;
1040 if (init_table
[itpos0
]) return;
1041 fra
.me
.prev
= stack_frame_head
; stack_frame_head
= &fra
.me
;
1042 fra
.me
.file
= LOCATE_standard___collection___list
;
1044 fra
.me
.meth
= LOCATE_standard___collection___list___List___init
;
1045 fra
.me
.has_broke
= 0;
1046 fra
.me
.REG_size
= 1;
1047 fra
.me
.nitni_local_ref_head
= NULL
;
1048 fra
.me
.REG
[0] = NIT_NULL
;
1050 stack_frame_head
= fra
.me
.prev
;
1051 init_table
[itpos0
] = 1;
1054 static const char LOCATE_standard___collection___list___List___from
[] = "list::List::from";
1055 void standard___collection___list___List___from(val_t p0
, val_t p1
, int* init_table
){
1056 int itpos1
= VAL2OBJ(p0
)->vft
[INIT_TABLE_POS_standard___collection___list___List
].i
;
1057 struct {struct stack_frame_t me
; val_t MORE_REG
[1];} fra
;
1059 if (init_table
[itpos1
]) return;
1060 fra
.me
.prev
= stack_frame_head
; stack_frame_head
= &fra
.me
;
1061 fra
.me
.file
= LOCATE_standard___collection___list
;
1063 fra
.me
.meth
= LOCATE_standard___collection___list___List___from
;
1064 fra
.me
.has_broke
= 0;
1065 fra
.me
.REG_size
= 2;
1066 fra
.me
.nitni_local_ref_head
= NULL
;
1067 fra
.me
.REG
[0] = NIT_NULL
;
1068 fra
.me
.REG
[1] = NIT_NULL
;
1071 /* ../lib/standard/collection/list.nit:189 */
1072 CALL_standard___collection___abstract_collection___Sequence___append(fra
.me
.REG
[0])(fra
.me
.REG
[0], fra
.me
.REG
[1]);
1073 stack_frame_head
= fra
.me
.prev
;
1074 init_table
[itpos1
] = 1;
1077 static const char LOCATE_standard___collection___list___List___get_node
[] = "list::List::get_node";
1078 val_t
standard___collection___list___List___get_node(val_t p0
, val_t p1
){
1079 struct {struct stack_frame_t me
; val_t MORE_REG
[2];} fra
;
1084 fra
.me
.prev
= stack_frame_head
; stack_frame_head
= &fra
.me
;
1085 fra
.me
.file
= LOCATE_standard___collection___list
;
1087 fra
.me
.meth
= LOCATE_standard___collection___list___List___get_node
;
1088 fra
.me
.has_broke
= 0;
1089 fra
.me
.REG_size
= 3;
1090 fra
.me
.nitni_local_ref_head
= NULL
;
1091 fra
.me
.REG
[0] = NIT_NULL
;
1092 fra
.me
.REG
[1] = NIT_NULL
;
1093 fra
.me
.REG
[2] = NIT_NULL
;
1096 /* ../lib/standard/collection/list.nit:200 */
1097 fra
.me
.REG
[0] = ATTR_standard___collection___list___List____head(fra
.me
.REG
[0]);
1098 /* ../lib/standard/collection/list.nit:201 */
1100 REGB2
= TAG_Bool(VAL_ISA(REGB1
, VTCOLOR_standard___kernel___Comparable___OTHER(REGB0
), VTID_standard___kernel___Comparable___OTHER(REGB0
))) /*cast OTHER*/;
1101 if (UNTAG_Bool(REGB2
)) {
1103 nit_abort("Cast failed", NULL
, LOCATE_standard___kernel
, 0);
1105 /* ../lib/standard/kernel.nit:235 */
1106 REGB1
= TAG_Bool(UNTAG_Int(REGB0
)<UNTAG_Int(REGB1
));
1107 /* ../lib/standard/collection/list.nit:201 */
1108 if (UNTAG_Bool(REGB1
)) {
1109 /* ../lib/standard/collection/list.nit:202 */
1110 fra
.me
.REG
[1] = NIT_NULL
;
1113 /* ../lib/standard/collection/list.nit:204 */
1115 REGB1
= TAG_Bool(fra
.me
.REG
[0]==NIT_NULL
);
1116 if (UNTAG_Bool(REGB1
)) {
1118 REGB2
= TAG_Bool(fra
.me
.REG
[0]==NIT_NULL
);
1119 if (UNTAG_Bool(REGB2
)) {
1120 REGB2
= TAG_Bool(0);
1123 REGB2
= CALL_standard___kernel___Object_____eqeq(fra
.me
.REG
[0])(fra
.me
.REG
[0], NIT_NULL
);
1127 REGB1
= TAG_Bool(!UNTAG_Bool(REGB1
));
1128 if (UNTAG_Bool(REGB1
)) {
1130 REGB2
= TAG_Bool(VAL_ISA(REGB1
, VTCOLOR_standard___kernel___Comparable___OTHER(REGB0
), VTID_standard___kernel___Comparable___OTHER(REGB0
))) /*cast OTHER*/;
1131 if (UNTAG_Bool(REGB2
)) {
1133 nit_abort("Cast failed", NULL
, LOCATE_standard___kernel
, 0);
1135 /* ../lib/standard/kernel.nit:237 */
1136 REGB1
= TAG_Bool(UNTAG_Int(REGB0
)>UNTAG_Int(REGB1
));
1138 /* ../lib/standard/collection/list.nit:204 */
1139 REGB2
= TAG_Bool(0);
1142 if (UNTAG_Bool(REGB1
)) {
1143 /* ../lib/standard/collection/list.nit:205 */
1144 REGB1
= TAG_Bool(fra
.me
.REG
[0]==NIT_NULL
);
1145 if (UNTAG_Bool(REGB1
)) {
1146 nit_abort("Reciever is null", NULL
, LOCATE_standard___collection___list
, 205);
1148 fra
.me
.REG
[2] = CALL_standard___collection___list___ListNode___next(fra
.me
.REG
[0])(fra
.me
.REG
[0]);
1149 fra
.me
.REG
[0] = fra
.me
.REG
[2];
1150 /* ../lib/standard/collection/list.nit:206 */
1152 /* ../lib/standard/kernel.nit:240 */
1153 REGB1
= TAG_Int(UNTAG_Int(REGB0
)-UNTAG_Int(REGB1
));
1154 /* ../lib/standard/collection/list.nit:206 */
1157 /* ../lib/standard/collection/list.nit:204 */
1162 /* ../lib/standard/collection/list.nit:208 */
1163 fra
.me
.REG
[1] = fra
.me
.REG
[0];
1166 stack_frame_head
= fra
.me
.prev
;
1167 return fra
.me
.REG
[1];
1169 static const char LOCATE_standard___collection___list___List___search_node_after
[] = "list::List::search_node_after";
1170 val_t
standard___collection___list___List___search_node_after(val_t p0
, val_t p1
, val_t p2
){
1171 struct {struct stack_frame_t me
; val_t MORE_REG
[2];} fra
;
1175 fra
.me
.prev
= stack_frame_head
; stack_frame_head
= &fra
.me
;
1176 fra
.me
.file
= LOCATE_standard___collection___list
;
1178 fra
.me
.meth
= LOCATE_standard___collection___list___List___search_node_after
;
1179 fra
.me
.has_broke
= 0;
1180 fra
.me
.REG_size
= 3;
1181 fra
.me
.nitni_local_ref_head
= NULL
;
1182 fra
.me
.REG
[0] = NIT_NULL
;
1183 fra
.me
.REG
[1] = NIT_NULL
;
1184 fra
.me
.REG
[2] = NIT_NULL
;
1188 /* ../lib/standard/collection/list.nit:215 */
1190 REGB0
= TAG_Bool(fra
.me
.REG
[2]==NIT_NULL
);
1191 if (UNTAG_Bool(REGB0
)) {
1193 REGB1
= TAG_Bool(fra
.me
.REG
[2]==NIT_NULL
);
1194 if (UNTAG_Bool(REGB1
)) {
1195 REGB1
= TAG_Bool(0);
1198 REGB1
= CALL_standard___kernel___Object_____eqeq(fra
.me
.REG
[2])(fra
.me
.REG
[2], NIT_NULL
);
1202 REGB0
= TAG_Bool(!UNTAG_Bool(REGB0
));
1203 if (UNTAG_Bool(REGB0
)) {
1204 REGB0
= TAG_Bool(fra
.me
.REG
[2]==NIT_NULL
);
1205 if (UNTAG_Bool(REGB0
)) {
1206 nit_abort("Reciever is null", NULL
, LOCATE_standard___collection___list
, 215);
1208 fra
.me
.REG
[0] = CALL_standard___collection___abstract_collection___Container___item(fra
.me
.REG
[2])(fra
.me
.REG
[2]);
1209 REGB0
= TAG_Bool(IS_EQUAL_NN(fra
.me
.REG
[0],fra
.me
.REG
[1]));
1210 if (UNTAG_Bool(REGB0
)) {
1212 REGB1
= TAG_Bool(fra
.me
.REG
[0]==NIT_NULL
);
1213 if (UNTAG_Bool(REGB1
)) {
1214 REGB1
= TAG_Bool(0);
1217 REGB1
= CALL_standard___kernel___Object_____eqeq(fra
.me
.REG
[0])(fra
.me
.REG
[0], fra
.me
.REG
[1]);
1221 REGB0
= TAG_Bool(!UNTAG_Bool(REGB0
));
1223 REGB1
= TAG_Bool(0);
1226 if (UNTAG_Bool(REGB0
)) {
1227 REGB0
= TAG_Bool(fra
.me
.REG
[2]==NIT_NULL
);
1228 if (UNTAG_Bool(REGB0
)) {
1229 nit_abort("Reciever is null", NULL
, LOCATE_standard___collection___list
, 215);
1231 fra
.me
.REG
[0] = CALL_standard___collection___list___ListNode___next(fra
.me
.REG
[2])(fra
.me
.REG
[2]);
1232 fra
.me
.REG
[2] = fra
.me
.REG
[0];
1238 /* ../lib/standard/collection/list.nit:216 */
1241 stack_frame_head
= fra
.me
.prev
;
1242 return fra
.me
.REG
[2];
1244 static const char LOCATE_standard___collection___list___List___remove_node
[] = "list::List::remove_node";
1245 void standard___collection___list___List___remove_node(val_t p0
, val_t p1
){
1246 struct {struct stack_frame_t me
; val_t MORE_REG
[2];} fra
;
1250 fra
.me
.prev
= stack_frame_head
; stack_frame_head
= &fra
.me
;
1251 fra
.me
.file
= LOCATE_standard___collection___list
;
1253 fra
.me
.meth
= LOCATE_standard___collection___list___List___remove_node
;
1254 fra
.me
.has_broke
= 0;
1255 fra
.me
.REG_size
= 3;
1256 fra
.me
.nitni_local_ref_head
= NULL
;
1257 fra
.me
.REG
[0] = NIT_NULL
;
1258 fra
.me
.REG
[1] = NIT_NULL
;
1259 fra
.me
.REG
[2] = NIT_NULL
;
1262 /* ../lib/standard/collection/list.nit:222 */
1263 fra
.me
.REG
[2] = CALL_standard___collection___list___ListNode___prev(fra
.me
.REG
[1])(fra
.me
.REG
[1]);
1264 REGB0
= TAG_Bool(fra
.me
.REG
[2]==NIT_NULL
);
1265 if (UNTAG_Bool(REGB0
)) {
1267 REGB1
= TAG_Bool(fra
.me
.REG
[2]==NIT_NULL
);
1268 if (UNTAG_Bool(REGB1
)) {
1269 REGB1
= TAG_Bool(0);
1272 REGB1
= CALL_standard___kernel___Object_____eqeq(fra
.me
.REG
[2])(fra
.me
.REG
[2], NIT_NULL
);
1276 if (UNTAG_Bool(REGB0
)) {
1277 /* ../lib/standard/collection/list.nit:223 */
1278 fra
.me
.REG
[2] = CALL_standard___collection___list___ListNode___next(fra
.me
.REG
[1])(fra
.me
.REG
[1]);
1279 ATTR_standard___collection___list___List____head(fra
.me
.REG
[0]) = fra
.me
.REG
[2];
1280 /* ../lib/standard/collection/list.nit:224 */
1281 fra
.me
.REG
[2] = CALL_standard___collection___list___ListNode___next(fra
.me
.REG
[1])(fra
.me
.REG
[1]);
1282 REGB0
= TAG_Bool(fra
.me
.REG
[2]==NIT_NULL
);
1283 if (UNTAG_Bool(REGB0
)) {
1285 REGB1
= TAG_Bool(fra
.me
.REG
[2]==NIT_NULL
);
1286 if (UNTAG_Bool(REGB1
)) {
1287 REGB1
= TAG_Bool(0);
1290 REGB1
= CALL_standard___kernel___Object_____eqeq(fra
.me
.REG
[2])(fra
.me
.REG
[2], NIT_NULL
);
1294 if (UNTAG_Bool(REGB0
)) {
1295 /* ../lib/standard/collection/list.nit:225 */
1296 ATTR_standard___collection___list___List____tail(fra
.me
.REG
[0]) = NIT_NULL
;
1298 /* ../lib/standard/collection/list.nit:227 */
1299 fra
.me
.REG
[2] = CALL_standard___collection___list___ListNode___next(fra
.me
.REG
[1])(fra
.me
.REG
[1]);
1300 REGB0
= TAG_Bool(fra
.me
.REG
[2]==NIT_NULL
);
1301 if (UNTAG_Bool(REGB0
)) {
1302 nit_abort("Reciever is null", NULL
, LOCATE_standard___collection___list
, 227);
1304 CALL_standard___collection___list___ListNode___prev__eq(fra
.me
.REG
[2])(fra
.me
.REG
[2], NIT_NULL
);
1307 /* ../lib/standard/collection/list.nit:229 */
1308 fra
.me
.REG
[2] = CALL_standard___collection___list___ListNode___next(fra
.me
.REG
[1])(fra
.me
.REG
[1]);
1309 REGB0
= TAG_Bool(fra
.me
.REG
[2]==NIT_NULL
);
1310 if (UNTAG_Bool(REGB0
)) {
1312 REGB1
= TAG_Bool(fra
.me
.REG
[2]==NIT_NULL
);
1313 if (UNTAG_Bool(REGB1
)) {
1314 REGB1
= TAG_Bool(0);
1317 REGB1
= CALL_standard___kernel___Object_____eqeq(fra
.me
.REG
[2])(fra
.me
.REG
[2], NIT_NULL
);
1321 if (UNTAG_Bool(REGB0
)) {
1322 /* ../lib/standard/collection/list.nit:230 */
1323 fra
.me
.REG
[2] = CALL_standard___collection___list___ListNode___prev(fra
.me
.REG
[1])(fra
.me
.REG
[1]);
1324 ATTR_standard___collection___list___List____tail(fra
.me
.REG
[0]) = fra
.me
.REG
[2];
1325 /* ../lib/standard/collection/list.nit:231 */
1326 fra
.me
.REG
[2] = CALL_standard___collection___list___ListNode___prev(fra
.me
.REG
[1])(fra
.me
.REG
[1]);
1327 REGB0
= TAG_Bool(fra
.me
.REG
[2]==NIT_NULL
);
1328 if (UNTAG_Bool(REGB0
)) {
1329 nit_abort("Reciever is null", NULL
, LOCATE_standard___collection___list
, 231);
1331 CALL_standard___collection___list___ListNode___next__eq(fra
.me
.REG
[2])(fra
.me
.REG
[2], NIT_NULL
);
1333 /* ../lib/standard/collection/list.nit:233 */
1334 fra
.me
.REG
[2] = CALL_standard___collection___list___ListNode___prev(fra
.me
.REG
[1])(fra
.me
.REG
[1]);
1335 fra
.me
.REG
[0] = CALL_standard___collection___list___ListNode___next(fra
.me
.REG
[1])(fra
.me
.REG
[1]);
1336 REGB0
= TAG_Bool(fra
.me
.REG
[2]==NIT_NULL
);
1337 if (UNTAG_Bool(REGB0
)) {
1338 nit_abort("Reciever is null", NULL
, LOCATE_standard___collection___list
, 233);
1340 CALL_standard___collection___list___ListNode___next__eq(fra
.me
.REG
[2])(fra
.me
.REG
[2], fra
.me
.REG
[0]);
1341 /* ../lib/standard/collection/list.nit:234 */
1342 fra
.me
.REG
[0] = CALL_standard___collection___list___ListNode___next(fra
.me
.REG
[1])(fra
.me
.REG
[1]);
1343 fra
.me
.REG
[1] = CALL_standard___collection___list___ListNode___prev(fra
.me
.REG
[1])(fra
.me
.REG
[1]);
1344 REGB0
= TAG_Bool(fra
.me
.REG
[0]==NIT_NULL
);
1345 if (UNTAG_Bool(REGB0
)) {
1346 nit_abort("Reciever is null", NULL
, LOCATE_standard___collection___list
, 234);
1348 CALL_standard___collection___list___ListNode___prev__eq(fra
.me
.REG
[0])(fra
.me
.REG
[0], fra
.me
.REG
[1]);
1351 stack_frame_head
= fra
.me
.prev
;
1354 static const char LOCATE_standard___collection___list___List___insert_before
[] = "list::List::insert_before";
1355 void standard___collection___list___List___insert_before(val_t p0
, val_t p1
, val_t p2
){
1356 struct {struct stack_frame_t me
; val_t MORE_REG
[3];} fra
;
1360 fra
.me
.prev
= stack_frame_head
; stack_frame_head
= &fra
.me
;
1361 fra
.me
.file
= LOCATE_standard___collection___list
;
1363 fra
.me
.meth
= LOCATE_standard___collection___list___List___insert_before
;
1364 fra
.me
.has_broke
= 0;
1365 fra
.me
.REG_size
= 4;
1366 fra
.me
.nitni_local_ref_head
= NULL
;
1367 fra
.me
.REG
[0] = NIT_NULL
;
1368 fra
.me
.REG
[1] = NIT_NULL
;
1369 fra
.me
.REG
[2] = NIT_NULL
;
1370 fra
.me
.REG
[3] = NIT_NULL
;
1374 /* ../lib/standard/collection/list.nit:240 */
1375 fra
.me
.REG
[1] = NEW_ListNode_standard___collection___list___ListNode___init(fra
.me
.REG
[1]);
1376 /* ../lib/standard/collection/list.nit:241 */
1377 fra
.me
.REG
[3] = CALL_standard___collection___list___ListNode___prev(fra
.me
.REG
[2])(fra
.me
.REG
[2]);
1378 /* ../lib/standard/collection/list.nit:242 */
1379 REGB0
= TAG_Bool(fra
.me
.REG
[3]==NIT_NULL
);
1380 if (UNTAG_Bool(REGB0
)) {
1382 REGB1
= TAG_Bool(fra
.me
.REG
[3]==NIT_NULL
);
1383 if (UNTAG_Bool(REGB1
)) {
1384 REGB1
= TAG_Bool(0);
1387 REGB1
= CALL_standard___kernel___Object_____eqeq(fra
.me
.REG
[3])(fra
.me
.REG
[3], NIT_NULL
);
1391 if (UNTAG_Bool(REGB0
)) {
1392 /* ../lib/standard/collection/list.nit:243 */
1393 ATTR_standard___collection___list___List____head(fra
.me
.REG
[0]) = fra
.me
.REG
[1];
1395 /* ../lib/standard/collection/list.nit:245 */
1396 REGB0
= TAG_Bool(fra
.me
.REG
[3]==NIT_NULL
);
1397 if (UNTAG_Bool(REGB0
)) {
1398 nit_abort("Reciever is null", NULL
, LOCATE_standard___collection___list
, 245);
1400 CALL_standard___collection___list___ListNode___next__eq(fra
.me
.REG
[3])(fra
.me
.REG
[3], fra
.me
.REG
[1]);
1402 /* ../lib/standard/collection/list.nit:247 */
1403 CALL_standard___collection___list___ListNode___prev__eq(fra
.me
.REG
[1])(fra
.me
.REG
[1], fra
.me
.REG
[3]);
1404 /* ../lib/standard/collection/list.nit:248 */
1405 CALL_standard___collection___list___ListNode___next__eq(fra
.me
.REG
[1])(fra
.me
.REG
[1], fra
.me
.REG
[2]);
1406 /* ../lib/standard/collection/list.nit:249 */
1407 CALL_standard___collection___list___ListNode___prev__eq(fra
.me
.REG
[2])(fra
.me
.REG
[2], fra
.me
.REG
[1]);
1408 stack_frame_head
= fra
.me
.prev
;
1411 static const char LOCATE_standard___collection___list___ListIterator___item
[] = "list::ListIterator::(abstract_collection::Iterator::item)";
1412 val_t
standard___collection___list___ListIterator___item(val_t p0
){
1413 struct {struct stack_frame_t me
;} fra
;
1416 fra
.me
.prev
= stack_frame_head
; stack_frame_head
= &fra
.me
;
1417 fra
.me
.file
= LOCATE_standard___collection___list
;
1419 fra
.me
.meth
= LOCATE_standard___collection___list___ListIterator___item
;
1420 fra
.me
.has_broke
= 0;
1421 fra
.me
.REG_size
= 1;
1422 fra
.me
.nitni_local_ref_head
= NULL
;
1423 fra
.me
.REG
[0] = NIT_NULL
;
1425 /* ../lib/standard/collection/list.nit:256 */
1426 fra
.me
.REG
[0] = ATTR_standard___collection___list___ListIterator____node(fra
.me
.REG
[0]);
1427 REGB0
= TAG_Bool(fra
.me
.REG
[0]==NIT_NULL
);
1428 if (UNTAG_Bool(REGB0
)) {
1429 nit_abort("Reciever is null", NULL
, LOCATE_standard___collection___list
, 256);
1431 fra
.me
.REG
[0] = CALL_standard___collection___abstract_collection___Container___item(fra
.me
.REG
[0])(fra
.me
.REG
[0]);
1434 stack_frame_head
= fra
.me
.prev
;
1435 return fra
.me
.REG
[0];
1437 static const char LOCATE_standard___collection___list___ListIterator___item__eq
[] = "list::ListIterator::item=";
1438 void standard___collection___list___ListIterator___item__eq(val_t p0
, val_t p1
){
1439 struct {struct stack_frame_t me
; val_t MORE_REG
[1];} fra
;
1442 fra
.me
.prev
= stack_frame_head
; stack_frame_head
= &fra
.me
;
1443 fra
.me
.file
= LOCATE_standard___collection___list
;
1445 fra
.me
.meth
= LOCATE_standard___collection___list___ListIterator___item__eq
;
1446 fra
.me
.has_broke
= 0;
1447 fra
.me
.REG_size
= 2;
1448 fra
.me
.nitni_local_ref_head
= NULL
;
1449 fra
.me
.REG
[0] = NIT_NULL
;
1450 fra
.me
.REG
[1] = NIT_NULL
;
1453 /* ../lib/standard/collection/list.nit:258 */
1454 fra
.me
.REG
[0] = ATTR_standard___collection___list___ListIterator____node(fra
.me
.REG
[0]);
1455 REGB0
= TAG_Bool(fra
.me
.REG
[0]==NIT_NULL
);
1456 if (UNTAG_Bool(REGB0
)) {
1457 nit_abort("Reciever is null", NULL
, LOCATE_standard___collection___list
, 258);
1459 CALL_standard___collection___abstract_collection___Container___item__eq(fra
.me
.REG
[0])(fra
.me
.REG
[0], fra
.me
.REG
[1]);
1460 stack_frame_head
= fra
.me
.prev
;
1463 static const char LOCATE_standard___collection___list___ListIterator___is_ok
[] = "list::ListIterator::(abstract_collection::Iterator::is_ok)";
1464 val_t
standard___collection___list___ListIterator___is_ok(val_t p0
){
1465 struct {struct stack_frame_t me
;} fra
;
1469 fra
.me
.prev
= stack_frame_head
; stack_frame_head
= &fra
.me
;
1470 fra
.me
.file
= LOCATE_standard___collection___list
;
1472 fra
.me
.meth
= LOCATE_standard___collection___list___ListIterator___is_ok
;
1473 fra
.me
.has_broke
= 0;
1474 fra
.me
.REG_size
= 1;
1475 fra
.me
.nitni_local_ref_head
= NULL
;
1476 fra
.me
.REG
[0] = NIT_NULL
;
1478 /* ../lib/standard/collection/list.nit:260 */
1479 fra
.me
.REG
[0] = ATTR_standard___collection___list___ListIterator____node(fra
.me
.REG
[0]);
1480 REGB0
= TAG_Bool(fra
.me
.REG
[0]==NIT_NULL
);
1481 if (UNTAG_Bool(REGB0
)) {
1483 REGB1
= TAG_Bool(fra
.me
.REG
[0]==NIT_NULL
);
1484 if (UNTAG_Bool(REGB1
)) {
1485 REGB1
= TAG_Bool(0);
1488 REGB1
= CALL_standard___kernel___Object_____eqeq(fra
.me
.REG
[0])(fra
.me
.REG
[0], NIT_NULL
);
1492 REGB0
= TAG_Bool(!UNTAG_Bool(REGB0
));
1495 stack_frame_head
= fra
.me
.prev
;
1498 static const char LOCATE_standard___collection___list___ListIterator___next
[] = "list::ListIterator::(abstract_collection::Iterator::next)";
1499 void standard___collection___list___ListIterator___next(val_t p0
){
1500 struct {struct stack_frame_t me
; val_t MORE_REG
[1];} fra
;
1504 fra
.me
.prev
= stack_frame_head
; stack_frame_head
= &fra
.me
;
1505 fra
.me
.file
= LOCATE_standard___collection___list
;
1507 fra
.me
.meth
= LOCATE_standard___collection___list___ListIterator___next
;
1508 fra
.me
.has_broke
= 0;
1509 fra
.me
.REG_size
= 2;
1510 fra
.me
.nitni_local_ref_head
= NULL
;
1511 fra
.me
.REG
[0] = NIT_NULL
;
1512 fra
.me
.REG
[1] = NIT_NULL
;
1514 /* ../lib/standard/collection/list.nit:264 */
1515 fra
.me
.REG
[1] = ATTR_standard___collection___list___ListIterator____node(fra
.me
.REG
[0]);
1516 REGB0
= TAG_Bool(fra
.me
.REG
[1]==NIT_NULL
);
1517 if (UNTAG_Bool(REGB0
)) {
1518 nit_abort("Reciever is null", NULL
, LOCATE_standard___collection___list
, 264);
1520 fra
.me
.REG
[1] = CALL_standard___collection___list___ListNode___next(fra
.me
.REG
[1])(fra
.me
.REG
[1]);
1521 ATTR_standard___collection___list___ListIterator____node(fra
.me
.REG
[0]) = fra
.me
.REG
[1];
1522 /* ../lib/standard/collection/list.nit:265 */
1523 REGB0
= ATTR_standard___collection___list___ListIterator____index(fra
.me
.REG
[0]);
1525 /* ../lib/standard/kernel.nit:238 */
1526 REGB1
= TAG_Int(UNTAG_Int(REGB0
)+UNTAG_Int(REGB1
));
1527 /* ../lib/standard/collection/list.nit:265 */
1528 ATTR_standard___collection___list___ListIterator____index(fra
.me
.REG
[0]) = REGB1
;
1529 stack_frame_head
= fra
.me
.prev
;
1532 static const char LOCATE_standard___collection___list___ListIterator___init
[] = "list::ListIterator::init";
1533 void standard___collection___list___ListIterator___init(val_t p0
, val_t p1
, int* init_table
){
1534 int itpos2
= VAL2OBJ(p0
)->vft
[INIT_TABLE_POS_standard___collection___list___ListIterator
].i
;
1535 struct {struct stack_frame_t me
; val_t MORE_REG
[1];} fra
;
1538 if (init_table
[itpos2
]) return;
1539 fra
.me
.prev
= stack_frame_head
; stack_frame_head
= &fra
.me
;
1540 fra
.me
.file
= LOCATE_standard___collection___list
;
1542 fra
.me
.meth
= LOCATE_standard___collection___list___ListIterator___init
;
1543 fra
.me
.has_broke
= 0;
1544 fra
.me
.REG_size
= 2;
1545 fra
.me
.nitni_local_ref_head
= NULL
;
1546 fra
.me
.REG
[0] = NIT_NULL
;
1547 fra
.me
.REG
[1] = NIT_NULL
;
1550 /* ../lib/standard/collection/list.nit:271 */
1551 ATTR_standard___collection___list___ListIterator____list(fra
.me
.REG
[0]) = fra
.me
.REG
[1];
1552 /* ../lib/standard/collection/list.nit:272 */
1553 fra
.me
.REG
[1] = ATTR_standard___collection___list___List____head(fra
.me
.REG
[1]);
1554 ATTR_standard___collection___list___ListIterator____node(fra
.me
.REG
[0]) = fra
.me
.REG
[1];
1555 /* ../lib/standard/collection/list.nit:273 */
1557 ATTR_standard___collection___list___ListIterator____index(fra
.me
.REG
[0]) = REGB0
;
1558 stack_frame_head
= fra
.me
.prev
;
1559 init_table
[itpos2
] = 1;
1562 static const char LOCATE_standard___collection___list___ListIterator___index
[] = "list::ListIterator::(abstract_collection::IndexedIterator::index)";
1563 val_t
standard___collection___list___ListIterator___index(val_t p0
){
1564 struct {struct stack_frame_t me
;} fra
;
1567 fra
.me
.prev
= stack_frame_head
; stack_frame_head
= &fra
.me
;
1568 fra
.me
.file
= LOCATE_standard___collection___list
;
1570 fra
.me
.meth
= LOCATE_standard___collection___list___ListIterator___index
;
1571 fra
.me
.has_broke
= 0;
1572 fra
.me
.REG_size
= 1;
1573 fra
.me
.nitni_local_ref_head
= NULL
;
1574 fra
.me
.REG
[0] = NIT_NULL
;
1576 /* ../lib/standard/collection/list.nit:282 */
1577 REGB0
= TAG_Bool(ATTR_standard___collection___list___ListIterator____index(fra
.me
.REG
[0])!=NIT_NULL
);
1578 if (UNTAG_Bool(REGB0
)) {
1580 nit_abort("Uninitialized attribute %s", "_index", LOCATE_standard___collection___list
, 282);
1582 REGB0
= ATTR_standard___collection___list___ListIterator____index(fra
.me
.REG
[0]);
1583 stack_frame_head
= fra
.me
.prev
;
1586 static const char LOCATE_standard___collection___list___ListIterator___delete
[] = "list::ListIterator::delete";
1587 void standard___collection___list___ListIterator___delete(val_t p0
){
1588 struct {struct stack_frame_t me
; val_t MORE_REG
[2];} fra
;
1591 fra
.me
.prev
= stack_frame_head
; stack_frame_head
= &fra
.me
;
1592 fra
.me
.file
= LOCATE_standard___collection___list
;
1594 fra
.me
.meth
= LOCATE_standard___collection___list___ListIterator___delete
;
1595 fra
.me
.has_broke
= 0;
1596 fra
.me
.REG_size
= 3;
1597 fra
.me
.nitni_local_ref_head
= NULL
;
1598 fra
.me
.REG
[0] = NIT_NULL
;
1599 fra
.me
.REG
[1] = NIT_NULL
;
1600 fra
.me
.REG
[2] = NIT_NULL
;
1602 /* ../lib/standard/collection/list.nit:285 */
1603 fra
.me
.REG
[1] = fra
.me
.REG
[0];
1604 /* ../lib/standard/collection/list.nit:288 */
1605 REGB0
= TAG_Bool(ATTR_standard___collection___list___ListIterator____list(fra
.me
.REG
[1])!=NIT_NULL
);
1606 if (UNTAG_Bool(REGB0
)) {
1608 nit_abort("Uninitialized attribute %s", "_list", LOCATE_standard___collection___list
, 288);
1610 fra
.me
.REG
[2] = ATTR_standard___collection___list___ListIterator____list(fra
.me
.REG
[1]);
1611 fra
.me
.REG
[1] = ATTR_standard___collection___list___ListIterator____node(fra
.me
.REG
[1]);
1612 REGB0
= TAG_Bool(fra
.me
.REG
[1]!=NIT_NULL
);
1613 if (UNTAG_Bool(REGB0
)) {
1615 nit_abort("Cast failed", NULL
, LOCATE_standard___collection___list
, 288);
1617 CALL_standard___collection___list___List___remove_node(fra
.me
.REG
[2])(fra
.me
.REG
[2], fra
.me
.REG
[1]);
1618 stack_frame_head
= fra
.me
.prev
;
1621 static const char LOCATE_standard___collection___list___ListIterator___insert_before
[] = "list::ListIterator::insert_before";
1622 void standard___collection___list___ListIterator___insert_before(val_t p0
, val_t p1
){
1623 struct {struct stack_frame_t me
; val_t MORE_REG
[3];} fra
;
1626 fra
.me
.prev
= stack_frame_head
; stack_frame_head
= &fra
.me
;
1627 fra
.me
.file
= LOCATE_standard___collection___list
;
1629 fra
.me
.meth
= LOCATE_standard___collection___list___ListIterator___insert_before
;
1630 fra
.me
.has_broke
= 0;
1631 fra
.me
.REG_size
= 4;
1632 fra
.me
.nitni_local_ref_head
= NULL
;
1633 fra
.me
.REG
[0] = NIT_NULL
;
1634 fra
.me
.REG
[1] = NIT_NULL
;
1635 fra
.me
.REG
[2] = NIT_NULL
;
1636 fra
.me
.REG
[3] = NIT_NULL
;
1639 /* ../lib/standard/collection/list.nit:291 */
1640 fra
.me
.REG
[2] = fra
.me
.REG
[0];
1641 /* ../lib/standard/collection/list.nit:294 */
1642 REGB0
= TAG_Bool(ATTR_standard___collection___list___ListIterator____list(fra
.me
.REG
[2])!=NIT_NULL
);
1643 if (UNTAG_Bool(REGB0
)) {
1645 nit_abort("Uninitialized attribute %s", "_list", LOCATE_standard___collection___list
, 294);
1647 fra
.me
.REG
[3] = ATTR_standard___collection___list___ListIterator____list(fra
.me
.REG
[2]);
1648 fra
.me
.REG
[2] = ATTR_standard___collection___list___ListIterator____node(fra
.me
.REG
[2]);
1649 REGB0
= TAG_Bool(fra
.me
.REG
[2]!=NIT_NULL
);
1650 if (UNTAG_Bool(REGB0
)) {
1652 nit_abort("Cast failed", NULL
, LOCATE_standard___collection___list
, 294);
1654 CALL_standard___collection___list___List___insert_before(fra
.me
.REG
[3])(fra
.me
.REG
[3], fra
.me
.REG
[1], fra
.me
.REG
[2]);
1655 stack_frame_head
= fra
.me
.prev
;
1658 static const char LOCATE_standard___collection___list___ListNode___init
[] = "list::ListNode::init";
1659 void standard___collection___list___ListNode___init(val_t p0
, val_t p1
, int* init_table
){
1660 int itpos3
= VAL2OBJ(p0
)->vft
[INIT_TABLE_POS_standard___collection___list___ListNode
].i
;
1661 struct {struct stack_frame_t me
; val_t MORE_REG
[3];} fra
;
1663 if (init_table
[itpos3
]) return;
1664 fra
.me
.prev
= stack_frame_head
; stack_frame_head
= &fra
.me
;
1665 fra
.me
.file
= LOCATE_standard___collection___list
;
1667 fra
.me
.meth
= LOCATE_standard___collection___list___ListNode___init
;
1668 fra
.me
.has_broke
= 0;
1669 fra
.me
.REG_size
= 4;
1670 fra
.me
.nitni_local_ref_head
= NULL
;
1671 fra
.me
.REG
[0] = NIT_NULL
;
1672 fra
.me
.REG
[1] = NIT_NULL
;
1673 fra
.me
.REG
[2] = NIT_NULL
;
1674 fra
.me
.REG
[3] = NIT_NULL
;
1677 /* ../lib/standard/collection/list.nit:301 */
1678 fra
.me
.REG
[2] = fra
.me
.REG
[0];
1679 fra
.me
.REG
[3] = fra
.me
.REG
[1];
1680 CALL_standard___collection___abstract_collection___Container___init(fra
.me
.REG
[0])(fra
.me
.REG
[0], fra
.me
.REG
[1], init_table
);
1681 /* ../lib/standard/collection/list.nit:303 */
1682 CALL_standard___collection___abstract_collection___Container___item__eq(fra
.me
.REG
[2])(fra
.me
.REG
[2], fra
.me
.REG
[3]);
1683 stack_frame_head
= fra
.me
.prev
;
1684 init_table
[itpos3
] = 1;
1687 static const char LOCATE_standard___collection___list___ListNode___next
[] = "list::ListNode::next";
1688 val_t
standard___collection___list___ListNode___next(val_t p0
){
1689 struct {struct stack_frame_t me
;} fra
;
1691 fra
.me
.prev
= stack_frame_head
; stack_frame_head
= &fra
.me
;
1692 fra
.me
.file
= LOCATE_standard___collection___list
;
1694 fra
.me
.meth
= LOCATE_standard___collection___list___ListNode___next
;
1695 fra
.me
.has_broke
= 0;
1696 fra
.me
.REG_size
= 1;
1697 fra
.me
.nitni_local_ref_head
= NULL
;
1698 fra
.me
.REG
[0] = NIT_NULL
;
1700 /* ../lib/standard/collection/list.nit:306 */
1701 fra
.me
.REG
[0] = ATTR_standard___collection___list___ListNode____next(fra
.me
.REG
[0]);
1702 stack_frame_head
= fra
.me
.prev
;
1703 return fra
.me
.REG
[0];
1705 static const char LOCATE_standard___collection___list___ListNode___next__eq
[] = "list::ListNode::next=";
1706 void standard___collection___list___ListNode___next__eq(val_t p0
, val_t p1
){
1707 struct {struct stack_frame_t me
; val_t MORE_REG
[1];} fra
;
1709 fra
.me
.prev
= stack_frame_head
; stack_frame_head
= &fra
.me
;
1710 fra
.me
.file
= LOCATE_standard___collection___list
;
1712 fra
.me
.meth
= LOCATE_standard___collection___list___ListNode___next__eq
;
1713 fra
.me
.has_broke
= 0;
1714 fra
.me
.REG_size
= 2;
1715 fra
.me
.nitni_local_ref_head
= NULL
;
1716 fra
.me
.REG
[0] = NIT_NULL
;
1717 fra
.me
.REG
[1] = NIT_NULL
;
1720 /* ../lib/standard/collection/list.nit:306 */
1721 ATTR_standard___collection___list___ListNode____next(fra
.me
.REG
[0]) = fra
.me
.REG
[1];
1722 stack_frame_head
= fra
.me
.prev
;
1725 static const char LOCATE_standard___collection___list___ListNode___prev
[] = "list::ListNode::prev";
1726 val_t
standard___collection___list___ListNode___prev(val_t p0
){
1727 struct {struct stack_frame_t me
;} fra
;
1729 fra
.me
.prev
= stack_frame_head
; stack_frame_head
= &fra
.me
;
1730 fra
.me
.file
= LOCATE_standard___collection___list
;
1732 fra
.me
.meth
= LOCATE_standard___collection___list___ListNode___prev
;
1733 fra
.me
.has_broke
= 0;
1734 fra
.me
.REG_size
= 1;
1735 fra
.me
.nitni_local_ref_head
= NULL
;
1736 fra
.me
.REG
[0] = NIT_NULL
;
1738 /* ../lib/standard/collection/list.nit:309 */
1739 fra
.me
.REG
[0] = ATTR_standard___collection___list___ListNode____prev(fra
.me
.REG
[0]);
1740 stack_frame_head
= fra
.me
.prev
;
1741 return fra
.me
.REG
[0];
1743 static const char LOCATE_standard___collection___list___ListNode___prev__eq
[] = "list::ListNode::prev=";
1744 void standard___collection___list___ListNode___prev__eq(val_t p0
, val_t p1
){
1745 struct {struct stack_frame_t me
; val_t MORE_REG
[1];} fra
;
1747 fra
.me
.prev
= stack_frame_head
; stack_frame_head
= &fra
.me
;
1748 fra
.me
.file
= LOCATE_standard___collection___list
;
1750 fra
.me
.meth
= LOCATE_standard___collection___list___ListNode___prev__eq
;
1751 fra
.me
.has_broke
= 0;
1752 fra
.me
.REG_size
= 2;
1753 fra
.me
.nitni_local_ref_head
= NULL
;
1754 fra
.me
.REG
[0] = NIT_NULL
;
1755 fra
.me
.REG
[1] = NIT_NULL
;
1758 /* ../lib/standard/collection/list.nit:309 */
1759 ATTR_standard___collection___list___ListNode____prev(fra
.me
.REG
[0]) = fra
.me
.REG
[1];
1760 stack_frame_head
= fra
.me
.prev
;