tools: clean Makefiles
[nit.git] / c_src / standard___collection___list._sep.c
1 /* This C file is generated by NIT to compile module standard___collection___list. */
2 #include "standard___collection___list._sep.h"
3 val_t standard___collection___list___List_____bra(val_t p0, val_t p1){
4 struct {struct stack_frame_t me;} fra;
5 val_t REGB0;
6 val_t tmp;
7 fra.me.prev = stack_frame_head; stack_frame_head = &fra.me;
8 fra.me.file = LOCATE_standard___collection___list;
9 fra.me.line = 21;
10 fra.me.meth = LOCATE_standard___collection___list___List_____bra;
11 fra.me.has_broke = 0;
12 fra.me.REG_size = 1;
13 fra.me.REG[0] = NIT_NULL;
14 fra.me.REG[0] = p0;
15 REGB0 = p1;
16 /* ./../lib/standard//collection//list.nit:22 */
17 fra.me.REG[0] = CALL_standard___collection___list___List___get_node(fra.me.REG[0])(fra.me.REG[0], REGB0);
18 REGB0 = TAG_Bool(fra.me.REG[0]==NIT_NULL);
19 if (UNTAG_Bool(REGB0)) {
20 nit_abort("Reciever is null", NULL, LOCATE_standard___collection___list, 22);
21 }
22 fra.me.REG[0] = CALL_standard___collection___abstract_collection___Container___item(fra.me.REG[0])(fra.me.REG[0]);
23 goto label1;
24 label1: while(0);
25 stack_frame_head = fra.me.prev;
26 return fra.me.REG[0];
27 }
28 void standard___collection___list___List_____braeq(val_t p0, val_t p1, val_t p2){
29 struct {struct stack_frame_t me; val_t MORE_REG[1];} fra;
30 val_t REGB0;
31 val_t tmp;
32 fra.me.prev = stack_frame_head; stack_frame_head = &fra.me;
33 fra.me.file = LOCATE_standard___collection___list;
34 fra.me.line = 24;
35 fra.me.meth = LOCATE_standard___collection___list___List_____braeq;
36 fra.me.has_broke = 0;
37 fra.me.REG_size = 2;
38 fra.me.REG[0] = NIT_NULL;
39 fra.me.REG[1] = NIT_NULL;
40 fra.me.REG[0] = p0;
41 REGB0 = p1;
42 fra.me.REG[1] = p2;
43 /* ./../lib/standard//collection//list.nit:24 */
44 fra.me.REG[0] = CALL_standard___collection___list___List___get_node(fra.me.REG[0])(fra.me.REG[0], REGB0);
45 REGB0 = TAG_Bool(fra.me.REG[0]==NIT_NULL);
46 if (UNTAG_Bool(REGB0)) {
47 nit_abort("Reciever is null", NULL, LOCATE_standard___collection___list, 24);
48 }
49 CALL_standard___collection___abstract_collection___Container___item__eq(fra.me.REG[0])(fra.me.REG[0], fra.me.REG[1]);
50 stack_frame_head = fra.me.prev;
51 return;
52 }
53 val_t standard___collection___list___List___first(val_t p0){
54 struct {struct stack_frame_t me;} fra;
55 val_t REGB0;
56 val_t tmp;
57 fra.me.prev = stack_frame_head; stack_frame_head = &fra.me;
58 fra.me.file = LOCATE_standard___collection___list;
59 fra.me.line = 26;
60 fra.me.meth = LOCATE_standard___collection___list___List___first;
61 fra.me.has_broke = 0;
62 fra.me.REG_size = 1;
63 fra.me.REG[0] = NIT_NULL;
64 fra.me.REG[0] = p0;
65 /* ./../lib/standard//collection//list.nit:27 */
66 fra.me.REG[0] = ATTR_standard___collection___list___List____head(fra.me.REG[0]);
67 REGB0 = TAG_Bool(fra.me.REG[0]==NIT_NULL);
68 if (UNTAG_Bool(REGB0)) {
69 nit_abort("Reciever is null", NULL, LOCATE_standard___collection___list, 27);
70 }
71 fra.me.REG[0] = CALL_standard___collection___abstract_collection___Container___item(fra.me.REG[0])(fra.me.REG[0]);
72 goto label1;
73 label1: while(0);
74 stack_frame_head = fra.me.prev;
75 return fra.me.REG[0];
76 }
77 void standard___collection___list___List___first__eq(val_t p0, val_t p1){
78 struct {struct stack_frame_t me; val_t MORE_REG[1];} fra;
79 val_t REGB0;
80 val_t tmp;
81 fra.me.prev = stack_frame_head; stack_frame_head = &fra.me;
82 fra.me.file = LOCATE_standard___collection___list;
83 fra.me.line = 29;
84 fra.me.meth = LOCATE_standard___collection___list___List___first__eq;
85 fra.me.has_broke = 0;
86 fra.me.REG_size = 2;
87 fra.me.REG[0] = NIT_NULL;
88 fra.me.REG[1] = NIT_NULL;
89 fra.me.REG[0] = p0;
90 fra.me.REG[1] = p1;
91 /* ./../lib/standard//collection//list.nit:30 */
92 fra.me.REG[0] = ATTR_standard___collection___list___List____head(fra.me.REG[0]);
93 REGB0 = TAG_Bool(fra.me.REG[0]==NIT_NULL);
94 if (UNTAG_Bool(REGB0)) {
95 nit_abort("Reciever is null", NULL, LOCATE_standard___collection___list, 30);
96 }
97 CALL_standard___collection___abstract_collection___Container___item__eq(fra.me.REG[0])(fra.me.REG[0], fra.me.REG[1]);
98 stack_frame_head = fra.me.prev;
99 return;
100 }
101 val_t standard___collection___list___List___last(val_t p0){
102 struct {struct stack_frame_t me;} fra;
103 val_t REGB0;
104 val_t tmp;
105 fra.me.prev = stack_frame_head; stack_frame_head = &fra.me;
106 fra.me.file = LOCATE_standard___collection___list;
107 fra.me.line = 32;
108 fra.me.meth = LOCATE_standard___collection___list___List___last;
109 fra.me.has_broke = 0;
110 fra.me.REG_size = 1;
111 fra.me.REG[0] = NIT_NULL;
112 fra.me.REG[0] = p0;
113 /* ./../lib/standard//collection//list.nit:33 */
114 fra.me.REG[0] = ATTR_standard___collection___list___List____tail(fra.me.REG[0]);
115 REGB0 = TAG_Bool(fra.me.REG[0]==NIT_NULL);
116 if (UNTAG_Bool(REGB0)) {
117 nit_abort("Reciever is null", NULL, LOCATE_standard___collection___list, 33);
118 }
119 fra.me.REG[0] = CALL_standard___collection___abstract_collection___Container___item(fra.me.REG[0])(fra.me.REG[0]);
120 goto label1;
121 label1: while(0);
122 stack_frame_head = fra.me.prev;
123 return fra.me.REG[0];
124 }
125 void standard___collection___list___List___last__eq(val_t p0, val_t p1){
126 struct {struct stack_frame_t me; val_t MORE_REG[1];} fra;
127 val_t REGB0;
128 val_t tmp;
129 fra.me.prev = stack_frame_head; stack_frame_head = &fra.me;
130 fra.me.file = LOCATE_standard___collection___list;
131 fra.me.line = 35;
132 fra.me.meth = LOCATE_standard___collection___list___List___last__eq;
133 fra.me.has_broke = 0;
134 fra.me.REG_size = 2;
135 fra.me.REG[0] = NIT_NULL;
136 fra.me.REG[1] = NIT_NULL;
137 fra.me.REG[0] = p0;
138 fra.me.REG[1] = p1;
139 /* ./../lib/standard//collection//list.nit:36 */
140 fra.me.REG[0] = ATTR_standard___collection___list___List____tail(fra.me.REG[0]);
141 REGB0 = TAG_Bool(fra.me.REG[0]==NIT_NULL);
142 if (UNTAG_Bool(REGB0)) {
143 nit_abort("Reciever is null", NULL, LOCATE_standard___collection___list, 36);
144 }
145 CALL_standard___collection___abstract_collection___Container___item__eq(fra.me.REG[0])(fra.me.REG[0], fra.me.REG[1]);
146 stack_frame_head = fra.me.prev;
147 return;
148 }
149 val_t standard___collection___list___List___is_empty(val_t p0){
150 struct {struct stack_frame_t me;} fra;
151 val_t REGB0;
152 val_t REGB1;
153 val_t tmp;
154 fra.me.prev = stack_frame_head; stack_frame_head = &fra.me;
155 fra.me.file = LOCATE_standard___collection___list;
156 fra.me.line = 40;
157 fra.me.meth = LOCATE_standard___collection___list___List___is_empty;
158 fra.me.has_broke = 0;
159 fra.me.REG_size = 1;
160 fra.me.REG[0] = NIT_NULL;
161 fra.me.REG[0] = p0;
162 /* ./../lib/standard//collection//list.nit:41 */
163 fra.me.REG[0] = ATTR_standard___collection___list___List____head(fra.me.REG[0]);
164 REGB0 = TAG_Bool(fra.me.REG[0]==NIT_NULL);
165 if (UNTAG_Bool(REGB0)) {
166 } else {
167 REGB1 = TAG_Bool(fra.me.REG[0]==NIT_NULL);
168 if (UNTAG_Bool(REGB1)) {
169 REGB1 = TAG_Bool(false);
170 REGB0 = REGB1;
171 } else {
172 REGB1 = CALL_standard___kernel___Object_____eqeq(fra.me.REG[0])(fra.me.REG[0], NIT_NULL);
173 REGB0 = REGB1;
174 }
175 }
176 goto label1;
177 label1: while(0);
178 stack_frame_head = fra.me.prev;
179 return REGB0;
180 }
181 val_t standard___collection___list___List___length(val_t p0){
182 struct {struct stack_frame_t me; val_t MORE_REG[1];} fra;
183 val_t REGB0;
184 val_t REGB1;
185 val_t REGB2;
186 val_t tmp;
187 fra.me.prev = stack_frame_head; stack_frame_head = &fra.me;
188 fra.me.file = LOCATE_standard___collection___list;
189 fra.me.line = 43;
190 fra.me.meth = LOCATE_standard___collection___list___List___length;
191 fra.me.has_broke = 0;
192 fra.me.REG_size = 2;
193 fra.me.REG[0] = NIT_NULL;
194 fra.me.REG[1] = NIT_NULL;
195 fra.me.REG[0] = p0;
196 /* ./../lib/standard//collection//list.nit:46 */
197 REGB0 = TAG_Int(0);
198 /* ./../lib/standard//collection//list.nit:47 */
199 fra.me.REG[0] = ATTR_standard___collection___list___List____head(fra.me.REG[0]);
200 /* ./../lib/standard//collection//list.nit:48 */
201 while(1) {
202 REGB1 = TAG_Bool(fra.me.REG[0]==NIT_NULL);
203 if (UNTAG_Bool(REGB1)) {
204 } else {
205 REGB2 = TAG_Bool(fra.me.REG[0]==NIT_NULL);
206 if (UNTAG_Bool(REGB2)) {
207 REGB2 = TAG_Bool(false);
208 REGB1 = REGB2;
209 } else {
210 REGB2 = CALL_standard___kernel___Object_____eqeq(fra.me.REG[0])(fra.me.REG[0], NIT_NULL);
211 REGB1 = REGB2;
212 }
213 }
214 REGB1 = TAG_Bool(!UNTAG_Bool(REGB1));
215 if (UNTAG_Bool(REGB1)) {
216 /* ./../lib/standard//collection//list.nit:49 */
217 REGB1 = TAG_Int(1);
218 /* ./../lib/standard//kernel.nit:235 */
219 REGB1 = TAG_Int(UNTAG_Int(REGB0)+UNTAG_Int(REGB1));
220 /* ./../lib/standard//collection//list.nit:49 */
221 REGB0 = REGB1;
222 /* ./../lib/standard//collection//list.nit:50 */
223 REGB1 = TAG_Bool(fra.me.REG[0]==NIT_NULL);
224 if (UNTAG_Bool(REGB1)) {
225 nit_abort("Reciever is null", NULL, LOCATE_standard___collection___list, 50);
226 }
227 fra.me.REG[1] = CALL_standard___collection___list___ListNode___next(fra.me.REG[0])(fra.me.REG[0]);
228 fra.me.REG[0] = fra.me.REG[1];
229 } else {
230 /* ./../lib/standard//collection//list.nit:48 */
231 goto label1;
232 }
233 }
234 label1: while(0);
235 /* ./../lib/standard//collection//list.nit:52 */
236 goto label2;
237 label2: while(0);
238 stack_frame_head = fra.me.prev;
239 return REGB0;
240 }
241 val_t standard___collection___list___List___has(val_t p0, val_t p1){
242 struct {struct stack_frame_t me; val_t MORE_REG[2];} fra;
243 val_t REGB0;
244 val_t REGB1;
245 val_t tmp;
246 fra.me.prev = stack_frame_head; stack_frame_head = &fra.me;
247 fra.me.file = LOCATE_standard___collection___list;
248 fra.me.line = 55;
249 fra.me.meth = LOCATE_standard___collection___list___List___has;
250 fra.me.has_broke = 0;
251 fra.me.REG_size = 3;
252 fra.me.REG[0] = NIT_NULL;
253 fra.me.REG[1] = NIT_NULL;
254 fra.me.REG[2] = NIT_NULL;
255 fra.me.REG[0] = p0;
256 fra.me.REG[1] = p1;
257 /* ./../lib/standard//collection//list.nit:56 */
258 fra.me.REG[2] = ATTR_standard___collection___list___List____head(fra.me.REG[0]);
259 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]);
260 REGB0 = TAG_Bool(fra.me.REG[2]==NIT_NULL);
261 if (UNTAG_Bool(REGB0)) {
262 } else {
263 REGB1 = TAG_Bool(fra.me.REG[2]==NIT_NULL);
264 if (UNTAG_Bool(REGB1)) {
265 REGB1 = TAG_Bool(false);
266 REGB0 = REGB1;
267 } else {
268 REGB1 = CALL_standard___kernel___Object_____eqeq(fra.me.REG[2])(fra.me.REG[2], NIT_NULL);
269 REGB0 = REGB1;
270 }
271 }
272 REGB0 = TAG_Bool(!UNTAG_Bool(REGB0));
273 goto label1;
274 label1: while(0);
275 stack_frame_head = fra.me.prev;
276 return REGB0;
277 }
278 val_t standard___collection___list___List___has_only(val_t p0, val_t p1){
279 struct {struct stack_frame_t me; val_t MORE_REG[2];} fra;
280 val_t REGB0;
281 val_t REGB1;
282 val_t tmp;
283 fra.me.prev = stack_frame_head; stack_frame_head = &fra.me;
284 fra.me.file = LOCATE_standard___collection___list;
285 fra.me.line = 58;
286 fra.me.meth = LOCATE_standard___collection___list___List___has_only;
287 fra.me.has_broke = 0;
288 fra.me.REG_size = 3;
289 fra.me.REG[0] = NIT_NULL;
290 fra.me.REG[1] = NIT_NULL;
291 fra.me.REG[2] = NIT_NULL;
292 fra.me.REG[0] = p0;
293 fra.me.REG[1] = p1;
294 /* ./../lib/standard//collection//list.nit:60 */
295 fra.me.REG[0] = ATTR_standard___collection___list___List____head(fra.me.REG[0]);
296 /* ./../lib/standard//collection//list.nit:61 */
297 while(1) {
298 REGB0 = TAG_Bool(fra.me.REG[0]==NIT_NULL);
299 if (UNTAG_Bool(REGB0)) {
300 } else {
301 REGB1 = TAG_Bool(fra.me.REG[0]==NIT_NULL);
302 if (UNTAG_Bool(REGB1)) {
303 REGB1 = TAG_Bool(false);
304 REGB0 = REGB1;
305 } else {
306 REGB1 = CALL_standard___kernel___Object_____eqeq(fra.me.REG[0])(fra.me.REG[0], NIT_NULL);
307 REGB0 = REGB1;
308 }
309 }
310 REGB0 = TAG_Bool(!UNTAG_Bool(REGB0));
311 if (UNTAG_Bool(REGB0)) {
312 /* ./../lib/standard//collection//list.nit:62 */
313 REGB0 = TAG_Bool(fra.me.REG[0]==NIT_NULL);
314 if (UNTAG_Bool(REGB0)) {
315 nit_abort("Reciever is null", NULL, LOCATE_standard___collection___list, 62);
316 }
317 fra.me.REG[2] = CALL_standard___collection___abstract_collection___Container___item(fra.me.REG[0])(fra.me.REG[0]);
318 REGB0 = TAG_Bool(IS_EQUAL_NN(fra.me.REG[2],fra.me.REG[1]));
319 if (UNTAG_Bool(REGB0)) {
320 } else {
321 REGB1 = TAG_Bool(fra.me.REG[2]==NIT_NULL);
322 if (UNTAG_Bool(REGB1)) {
323 REGB1 = TAG_Bool(false);
324 REGB0 = REGB1;
325 } else {
326 REGB1 = CALL_standard___kernel___Object_____eqeq(fra.me.REG[2])(fra.me.REG[2], fra.me.REG[1]);
327 REGB0 = REGB1;
328 }
329 }
330 REGB0 = TAG_Bool(!UNTAG_Bool(REGB0));
331 if (UNTAG_Bool(REGB0)) {
332 REGB0 = TAG_Bool(false);
333 goto label1;
334 }
335 /* ./../lib/standard//collection//list.nit:63 */
336 REGB1 = TAG_Bool(fra.me.REG[0]==NIT_NULL);
337 if (UNTAG_Bool(REGB1)) {
338 nit_abort("Reciever is null", NULL, LOCATE_standard___collection___list, 63);
339 }
340 fra.me.REG[2] = CALL_standard___collection___list___ListNode___next(fra.me.REG[0])(fra.me.REG[0]);
341 fra.me.REG[0] = fra.me.REG[2];
342 } else {
343 /* ./../lib/standard//collection//list.nit:61 */
344 goto label2;
345 }
346 }
347 label2: while(0);
348 /* ./../lib/standard//collection//list.nit:65 */
349 REGB1 = TAG_Bool(true);
350 REGB0 = REGB1;
351 goto label1;
352 label1: while(0);
353 stack_frame_head = fra.me.prev;
354 return REGB0;
355 }
356 val_t standard___collection___list___List___count(val_t p0, val_t p1){
357 struct {struct stack_frame_t me; val_t MORE_REG[2];} fra;
358 val_t REGB0;
359 val_t REGB1;
360 val_t REGB2;
361 val_t tmp;
362 fra.me.prev = stack_frame_head; stack_frame_head = &fra.me;
363 fra.me.file = LOCATE_standard___collection___list;
364 fra.me.line = 68;
365 fra.me.meth = LOCATE_standard___collection___list___List___count;
366 fra.me.has_broke = 0;
367 fra.me.REG_size = 3;
368 fra.me.REG[0] = NIT_NULL;
369 fra.me.REG[1] = NIT_NULL;
370 fra.me.REG[2] = NIT_NULL;
371 fra.me.REG[0] = p0;
372 fra.me.REG[1] = p1;
373 /* ./../lib/standard//collection//list.nit:70 */
374 REGB0 = TAG_Int(0);
375 /* ./../lib/standard//collection//list.nit:71 */
376 fra.me.REG[0] = ATTR_standard___collection___list___List____head(fra.me.REG[0]);
377 /* ./../lib/standard//collection//list.nit:72 */
378 while(1) {
379 REGB1 = TAG_Bool(fra.me.REG[0]==NIT_NULL);
380 if (UNTAG_Bool(REGB1)) {
381 } else {
382 REGB2 = TAG_Bool(fra.me.REG[0]==NIT_NULL);
383 if (UNTAG_Bool(REGB2)) {
384 REGB2 = TAG_Bool(false);
385 REGB1 = REGB2;
386 } else {
387 REGB2 = CALL_standard___kernel___Object_____eqeq(fra.me.REG[0])(fra.me.REG[0], NIT_NULL);
388 REGB1 = REGB2;
389 }
390 }
391 REGB1 = TAG_Bool(!UNTAG_Bool(REGB1));
392 if (UNTAG_Bool(REGB1)) {
393 /* ./../lib/standard//collection//list.nit:73 */
394 REGB1 = TAG_Bool(fra.me.REG[0]==NIT_NULL);
395 if (UNTAG_Bool(REGB1)) {
396 nit_abort("Reciever is null", NULL, LOCATE_standard___collection___list, 73);
397 }
398 fra.me.REG[2] = CALL_standard___collection___abstract_collection___Container___item(fra.me.REG[0])(fra.me.REG[0]);
399 REGB1 = TAG_Bool(IS_EQUAL_NN(fra.me.REG[2],fra.me.REG[1]));
400 if (UNTAG_Bool(REGB1)) {
401 } else {
402 REGB2 = TAG_Bool(fra.me.REG[2]==NIT_NULL);
403 if (UNTAG_Bool(REGB2)) {
404 REGB2 = TAG_Bool(false);
405 REGB1 = REGB2;
406 } else {
407 REGB2 = CALL_standard___kernel___Object_____eqeq(fra.me.REG[2])(fra.me.REG[2], fra.me.REG[1]);
408 REGB1 = REGB2;
409 }
410 }
411 REGB1 = TAG_Bool(!UNTAG_Bool(REGB1));
412 if (UNTAG_Bool(REGB1)) {
413 REGB1 = TAG_Int(1);
414 /* ./../lib/standard//kernel.nit:235 */
415 REGB1 = TAG_Int(UNTAG_Int(REGB0)+UNTAG_Int(REGB1));
416 /* ./../lib/standard//collection//list.nit:73 */
417 REGB0 = REGB1;
418 }
419 /* ./../lib/standard//collection//list.nit:74 */
420 REGB1 = TAG_Bool(fra.me.REG[0]==NIT_NULL);
421 if (UNTAG_Bool(REGB1)) {
422 nit_abort("Reciever is null", NULL, LOCATE_standard___collection___list, 74);
423 }
424 fra.me.REG[2] = CALL_standard___collection___list___ListNode___next(fra.me.REG[0])(fra.me.REG[0]);
425 fra.me.REG[0] = fra.me.REG[2];
426 } else {
427 /* ./../lib/standard//collection//list.nit:72 */
428 goto label1;
429 }
430 }
431 label1: while(0);
432 /* ./../lib/standard//collection//list.nit:76 */
433 goto label2;
434 label2: while(0);
435 stack_frame_head = fra.me.prev;
436 return REGB0;
437 }
438 void standard___collection___list___List___push(val_t p0, val_t p1){
439 struct {struct stack_frame_t me; val_t MORE_REG[2];} fra;
440 val_t REGB0;
441 val_t REGB1;
442 val_t tmp;
443 fra.me.prev = stack_frame_head; stack_frame_head = &fra.me;
444 fra.me.file = LOCATE_standard___collection___list;
445 fra.me.line = 81;
446 fra.me.meth = LOCATE_standard___collection___list___List___push;
447 fra.me.has_broke = 0;
448 fra.me.REG_size = 3;
449 fra.me.REG[0] = NIT_NULL;
450 fra.me.REG[1] = NIT_NULL;
451 fra.me.REG[2] = NIT_NULL;
452 fra.me.REG[0] = p0;
453 fra.me.REG[1] = p1;
454 /* ./../lib/standard//collection//list.nit:84 */
455 fra.me.REG[1] = NEW_ListNode_standard___collection___list___ListNode___init(fra.me.REG[1]);
456 /* ./../lib/standard//collection//list.nit:85 */
457 fra.me.REG[2] = ATTR_standard___collection___list___List____tail(fra.me.REG[0]);
458 REGB0 = TAG_Bool(fra.me.REG[2]==NIT_NULL);
459 if (UNTAG_Bool(REGB0)) {
460 } else {
461 REGB1 = TAG_Bool(fra.me.REG[2]==NIT_NULL);
462 if (UNTAG_Bool(REGB1)) {
463 REGB1 = TAG_Bool(false);
464 REGB0 = REGB1;
465 } else {
466 REGB1 = CALL_standard___kernel___Object_____eqeq(fra.me.REG[2])(fra.me.REG[2], NIT_NULL);
467 REGB0 = REGB1;
468 }
469 }
470 if (UNTAG_Bool(REGB0)) {
471 /* ./../lib/standard//collection//list.nit:86 */
472 ATTR_standard___collection___list___List____head(fra.me.REG[0]) = fra.me.REG[1];
473 } else {
474 /* ./../lib/standard//collection//list.nit:88 */
475 fra.me.REG[2] = ATTR_standard___collection___list___List____tail(fra.me.REG[0]);
476 REGB0 = TAG_Bool(fra.me.REG[2]==NIT_NULL);
477 if (UNTAG_Bool(REGB0)) {
478 nit_abort("Reciever is null", NULL, LOCATE_standard___collection___list, 88);
479 }
480 CALL_standard___collection___list___ListNode___next__eq(fra.me.REG[2])(fra.me.REG[2], fra.me.REG[1]);
481 /* ./../lib/standard//collection//list.nit:89 */
482 fra.me.REG[2] = ATTR_standard___collection___list___List____tail(fra.me.REG[0]);
483 CALL_standard___collection___list___ListNode___prev__eq(fra.me.REG[1])(fra.me.REG[1], fra.me.REG[2]);
484 }
485 /* ./../lib/standard//collection//list.nit:91 */
486 ATTR_standard___collection___list___List____tail(fra.me.REG[0]) = fra.me.REG[1];
487 stack_frame_head = fra.me.prev;
488 return;
489 }
490 void standard___collection___list___List___unshift(val_t p0, val_t p1){
491 struct {struct stack_frame_t me; val_t MORE_REG[2];} fra;
492 val_t REGB0;
493 val_t REGB1;
494 val_t tmp;
495 fra.me.prev = stack_frame_head; stack_frame_head = &fra.me;
496 fra.me.file = LOCATE_standard___collection___list;
497 fra.me.line = 94;
498 fra.me.meth = LOCATE_standard___collection___list___List___unshift;
499 fra.me.has_broke = 0;
500 fra.me.REG_size = 3;
501 fra.me.REG[0] = NIT_NULL;
502 fra.me.REG[1] = NIT_NULL;
503 fra.me.REG[2] = NIT_NULL;
504 fra.me.REG[0] = p0;
505 fra.me.REG[1] = p1;
506 /* ./../lib/standard//collection//list.nit:97 */
507 fra.me.REG[1] = NEW_ListNode_standard___collection___list___ListNode___init(fra.me.REG[1]);
508 /* ./../lib/standard//collection//list.nit:98 */
509 fra.me.REG[2] = ATTR_standard___collection___list___List____head(fra.me.REG[0]);
510 REGB0 = TAG_Bool(fra.me.REG[2]==NIT_NULL);
511 if (UNTAG_Bool(REGB0)) {
512 } else {
513 REGB1 = TAG_Bool(fra.me.REG[2]==NIT_NULL);
514 if (UNTAG_Bool(REGB1)) {
515 REGB1 = TAG_Bool(false);
516 REGB0 = REGB1;
517 } else {
518 REGB1 = CALL_standard___kernel___Object_____eqeq(fra.me.REG[2])(fra.me.REG[2], NIT_NULL);
519 REGB0 = REGB1;
520 }
521 }
522 if (UNTAG_Bool(REGB0)) {
523 /* ./../lib/standard//collection//list.nit:99 */
524 ATTR_standard___collection___list___List____tail(fra.me.REG[0]) = fra.me.REG[1];
525 } else {
526 /* ./../lib/standard//collection//list.nit:101 */
527 fra.me.REG[2] = ATTR_standard___collection___list___List____head(fra.me.REG[0]);
528 CALL_standard___collection___list___ListNode___next__eq(fra.me.REG[1])(fra.me.REG[1], fra.me.REG[2]);
529 /* ./../lib/standard//collection//list.nit:102 */
530 fra.me.REG[2] = ATTR_standard___collection___list___List____head(fra.me.REG[0]);
531 REGB0 = TAG_Bool(fra.me.REG[2]==NIT_NULL);
532 if (UNTAG_Bool(REGB0)) {
533 nit_abort("Reciever is null", NULL, LOCATE_standard___collection___list, 102);
534 }
535 CALL_standard___collection___list___ListNode___prev__eq(fra.me.REG[2])(fra.me.REG[2], fra.me.REG[1]);
536 }
537 /* ./../lib/standard//collection//list.nit:104 */
538 ATTR_standard___collection___list___List____head(fra.me.REG[0]) = fra.me.REG[1];
539 stack_frame_head = fra.me.prev;
540 return;
541 }
542 void standard___collection___list___List___link(val_t p0, val_t p1){
543 struct {struct stack_frame_t me; val_t MORE_REG[3];} fra;
544 val_t REGB0;
545 val_t REGB1;
546 val_t tmp;
547 fra.me.prev = stack_frame_head; stack_frame_head = &fra.me;
548 fra.me.file = LOCATE_standard___collection___list;
549 fra.me.line = 107;
550 fra.me.meth = LOCATE_standard___collection___list___List___link;
551 fra.me.has_broke = 0;
552 fra.me.REG_size = 4;
553 fra.me.REG[0] = NIT_NULL;
554 fra.me.REG[1] = NIT_NULL;
555 fra.me.REG[2] = NIT_NULL;
556 fra.me.REG[3] = NIT_NULL;
557 fra.me.REG[0] = p0;
558 fra.me.REG[1] = p1;
559 /* ./../lib/standard//collection//list.nit:112 */
560 fra.me.REG[2] = ATTR_standard___collection___list___List____tail(fra.me.REG[0]);
561 REGB0 = TAG_Bool(fra.me.REG[2]==NIT_NULL);
562 if (UNTAG_Bool(REGB0)) {
563 } else {
564 REGB1 = TAG_Bool(fra.me.REG[2]==NIT_NULL);
565 if (UNTAG_Bool(REGB1)) {
566 REGB1 = TAG_Bool(false);
567 REGB0 = REGB1;
568 } else {
569 REGB1 = CALL_standard___kernel___Object_____eqeq(fra.me.REG[2])(fra.me.REG[2], NIT_NULL);
570 REGB0 = REGB1;
571 }
572 }
573 if (UNTAG_Bool(REGB0)) {
574 /* ./../lib/standard//collection//list.nit:113 */
575 fra.me.REG[2] = ATTR_standard___collection___list___List____head(fra.me.REG[1]);
576 ATTR_standard___collection___list___List____head(fra.me.REG[0]) = fra.me.REG[2];
577 } else {
578 /* ./../lib/standard//collection//list.nit:114 */
579 fra.me.REG[2] = ATTR_standard___collection___list___List____head(fra.me.REG[1]);
580 REGB0 = TAG_Bool(fra.me.REG[2]==NIT_NULL);
581 if (UNTAG_Bool(REGB0)) {
582 } else {
583 REGB1 = TAG_Bool(fra.me.REG[2]==NIT_NULL);
584 if (UNTAG_Bool(REGB1)) {
585 REGB1 = TAG_Bool(false);
586 REGB0 = REGB1;
587 } else {
588 REGB1 = CALL_standard___kernel___Object_____eqeq(fra.me.REG[2])(fra.me.REG[2], NIT_NULL);
589 REGB0 = REGB1;
590 }
591 }
592 REGB0 = TAG_Bool(!UNTAG_Bool(REGB0));
593 if (UNTAG_Bool(REGB0)) {
594 /* ./../lib/standard//collection//list.nit:115 */
595 fra.me.REG[2] = ATTR_standard___collection___list___List____tail(fra.me.REG[0]);
596 fra.me.REG[3] = ATTR_standard___collection___list___List____head(fra.me.REG[1]);
597 REGB0 = TAG_Bool(fra.me.REG[2]==NIT_NULL);
598 if (UNTAG_Bool(REGB0)) {
599 nit_abort("Reciever is null", NULL, LOCATE_standard___collection___list, 115);
600 }
601 CALL_standard___collection___list___ListNode___next__eq(fra.me.REG[2])(fra.me.REG[2], fra.me.REG[3]);
602 /* ./../lib/standard//collection//list.nit:116 */
603 fra.me.REG[3] = ATTR_standard___collection___list___List____tail(fra.me.REG[0]);
604 REGB0 = TAG_Bool(fra.me.REG[3]==NIT_NULL);
605 if (UNTAG_Bool(REGB0)) {
606 nit_abort("Reciever is null", NULL, LOCATE_standard___collection___list, 116);
607 }
608 fra.me.REG[3] = CALL_standard___collection___list___ListNode___next(fra.me.REG[3])(fra.me.REG[3]);
609 fra.me.REG[2] = ATTR_standard___collection___list___List____tail(fra.me.REG[0]);
610 REGB0 = TAG_Bool(fra.me.REG[3]==NIT_NULL);
611 if (UNTAG_Bool(REGB0)) {
612 nit_abort("Reciever is null", NULL, LOCATE_standard___collection___list, 116);
613 }
614 CALL_standard___collection___list___ListNode___prev__eq(fra.me.REG[3])(fra.me.REG[3], fra.me.REG[2]);
615 }
616 }
617 /* ./../lib/standard//collection//list.nit:118 */
618 fra.me.REG[2] = ATTR_standard___collection___list___List____tail(fra.me.REG[1]);
619 ATTR_standard___collection___list___List____tail(fra.me.REG[0]) = fra.me.REG[2];
620 /* ./../lib/standard//collection//list.nit:119 */
621 CALL_standard___collection___abstract_collection___RemovableCollection___clear(fra.me.REG[1])(fra.me.REG[1]);
622 stack_frame_head = fra.me.prev;
623 return;
624 }
625 val_t standard___collection___list___List___pop(val_t p0){
626 struct {struct stack_frame_t me; val_t MORE_REG[2];} fra;
627 val_t REGB0;
628 val_t REGB1;
629 val_t tmp;
630 fra.me.prev = stack_frame_head; stack_frame_head = &fra.me;
631 fra.me.file = LOCATE_standard___collection___list;
632 fra.me.line = 124;
633 fra.me.meth = LOCATE_standard___collection___list___List___pop;
634 fra.me.has_broke = 0;
635 fra.me.REG_size = 3;
636 fra.me.REG[0] = NIT_NULL;
637 fra.me.REG[1] = NIT_NULL;
638 fra.me.REG[2] = NIT_NULL;
639 fra.me.REG[0] = p0;
640 /* ./../lib/standard//collection//list.nit:127 */
641 fra.me.REG[1] = ATTR_standard___collection___list___List____tail(fra.me.REG[0]);
642 /* ./../lib/standard//collection//list.nit:128 */
643 REGB0 = TAG_Bool(fra.me.REG[1]==NIT_NULL);
644 if (UNTAG_Bool(REGB0)) {
645 nit_abort("Reciever is null", NULL, LOCATE_standard___collection___list, 128);
646 }
647 fra.me.REG[2] = CALL_standard___collection___list___ListNode___prev(fra.me.REG[1])(fra.me.REG[1]);
648 ATTR_standard___collection___list___List____tail(fra.me.REG[0]) = fra.me.REG[2];
649 /* ./../lib/standard//collection//list.nit:129 */
650 REGB0 = TAG_Bool(fra.me.REG[1]==NIT_NULL);
651 if (UNTAG_Bool(REGB0)) {
652 nit_abort("Reciever is null", NULL, LOCATE_standard___collection___list, 129);
653 }
654 CALL_standard___collection___list___ListNode___prev__eq(fra.me.REG[1])(fra.me.REG[1], NIT_NULL);
655 /* ./../lib/standard//collection//list.nit:130 */
656 fra.me.REG[2] = ATTR_standard___collection___list___List____tail(fra.me.REG[0]);
657 REGB0 = TAG_Bool(fra.me.REG[2]==NIT_NULL);
658 if (UNTAG_Bool(REGB0)) {
659 } else {
660 REGB1 = TAG_Bool(fra.me.REG[2]==NIT_NULL);
661 if (UNTAG_Bool(REGB1)) {
662 REGB1 = TAG_Bool(false);
663 REGB0 = REGB1;
664 } else {
665 REGB1 = CALL_standard___kernel___Object_____eqeq(fra.me.REG[2])(fra.me.REG[2], NIT_NULL);
666 REGB0 = REGB1;
667 }
668 }
669 if (UNTAG_Bool(REGB0)) {
670 /* ./../lib/standard//collection//list.nit:131 */
671 ATTR_standard___collection___list___List____head(fra.me.REG[0]) = NIT_NULL;
672 } else {
673 /* ./../lib/standard//collection//list.nit:133 */
674 fra.me.REG[0] = ATTR_standard___collection___list___List____tail(fra.me.REG[0]);
675 REGB0 = TAG_Bool(fra.me.REG[0]==NIT_NULL);
676 if (UNTAG_Bool(REGB0)) {
677 nit_abort("Reciever is null", NULL, LOCATE_standard___collection___list, 133);
678 }
679 CALL_standard___collection___list___ListNode___next__eq(fra.me.REG[0])(fra.me.REG[0], NIT_NULL);
680 }
681 /* ./../lib/standard//collection//list.nit:135 */
682 REGB0 = TAG_Bool(fra.me.REG[1]==NIT_NULL);
683 if (UNTAG_Bool(REGB0)) {
684 nit_abort("Reciever is null", NULL, LOCATE_standard___collection___list, 135);
685 }
686 fra.me.REG[1] = CALL_standard___collection___abstract_collection___Container___item(fra.me.REG[1])(fra.me.REG[1]);
687 goto label1;
688 label1: while(0);
689 stack_frame_head = fra.me.prev;
690 return fra.me.REG[1];
691 }
692 val_t standard___collection___list___List___shift(val_t p0){
693 struct {struct stack_frame_t me; val_t MORE_REG[2];} fra;
694 val_t REGB0;
695 val_t REGB1;
696 val_t tmp;
697 fra.me.prev = stack_frame_head; stack_frame_head = &fra.me;
698 fra.me.file = LOCATE_standard___collection___list;
699 fra.me.line = 138;
700 fra.me.meth = LOCATE_standard___collection___list___List___shift;
701 fra.me.has_broke = 0;
702 fra.me.REG_size = 3;
703 fra.me.REG[0] = NIT_NULL;
704 fra.me.REG[1] = NIT_NULL;
705 fra.me.REG[2] = NIT_NULL;
706 fra.me.REG[0] = p0;
707 /* ./../lib/standard//collection//list.nit:141 */
708 fra.me.REG[1] = ATTR_standard___collection___list___List____head(fra.me.REG[0]);
709 /* ./../lib/standard//collection//list.nit:142 */
710 REGB0 = TAG_Bool(fra.me.REG[1]==NIT_NULL);
711 if (UNTAG_Bool(REGB0)) {
712 nit_abort("Reciever is null", NULL, LOCATE_standard___collection___list, 142);
713 }
714 fra.me.REG[2] = CALL_standard___collection___list___ListNode___next(fra.me.REG[1])(fra.me.REG[1]);
715 ATTR_standard___collection___list___List____head(fra.me.REG[0]) = fra.me.REG[2];
716 /* ./../lib/standard//collection//list.nit:143 */
717 REGB0 = TAG_Bool(fra.me.REG[1]==NIT_NULL);
718 if (UNTAG_Bool(REGB0)) {
719 nit_abort("Reciever is null", NULL, LOCATE_standard___collection___list, 143);
720 }
721 CALL_standard___collection___list___ListNode___next__eq(fra.me.REG[1])(fra.me.REG[1], NIT_NULL);
722 /* ./../lib/standard//collection//list.nit:144 */
723 fra.me.REG[2] = ATTR_standard___collection___list___List____head(fra.me.REG[0]);
724 REGB0 = TAG_Bool(fra.me.REG[2]==NIT_NULL);
725 if (UNTAG_Bool(REGB0)) {
726 } else {
727 REGB1 = TAG_Bool(fra.me.REG[2]==NIT_NULL);
728 if (UNTAG_Bool(REGB1)) {
729 REGB1 = TAG_Bool(false);
730 REGB0 = REGB1;
731 } else {
732 REGB1 = CALL_standard___kernel___Object_____eqeq(fra.me.REG[2])(fra.me.REG[2], NIT_NULL);
733 REGB0 = REGB1;
734 }
735 }
736 if (UNTAG_Bool(REGB0)) {
737 /* ./../lib/standard//collection//list.nit:145 */
738 ATTR_standard___collection___list___List____tail(fra.me.REG[0]) = NIT_NULL;
739 } else {
740 /* ./../lib/standard//collection//list.nit:147 */
741 fra.me.REG[0] = ATTR_standard___collection___list___List____head(fra.me.REG[0]);
742 REGB0 = TAG_Bool(fra.me.REG[0]==NIT_NULL);
743 if (UNTAG_Bool(REGB0)) {
744 nit_abort("Reciever is null", NULL, LOCATE_standard___collection___list, 147);
745 }
746 CALL_standard___collection___list___ListNode___prev__eq(fra.me.REG[0])(fra.me.REG[0], NIT_NULL);
747 }
748 /* ./../lib/standard//collection//list.nit:149 */
749 REGB0 = TAG_Bool(fra.me.REG[1]==NIT_NULL);
750 if (UNTAG_Bool(REGB0)) {
751 nit_abort("Reciever is null", NULL, LOCATE_standard___collection___list, 149);
752 }
753 fra.me.REG[1] = CALL_standard___collection___abstract_collection___Container___item(fra.me.REG[1])(fra.me.REG[1]);
754 goto label1;
755 label1: while(0);
756 stack_frame_head = fra.me.prev;
757 return fra.me.REG[1];
758 }
759 void standard___collection___list___List___remove(val_t p0, val_t p1){
760 struct {struct stack_frame_t me; val_t MORE_REG[2];} fra;
761 val_t REGB0;
762 val_t REGB1;
763 val_t tmp;
764 fra.me.prev = stack_frame_head; stack_frame_head = &fra.me;
765 fra.me.file = LOCATE_standard___collection___list;
766 fra.me.line = 152;
767 fra.me.meth = LOCATE_standard___collection___list___List___remove;
768 fra.me.has_broke = 0;
769 fra.me.REG_size = 3;
770 fra.me.REG[0] = NIT_NULL;
771 fra.me.REG[1] = NIT_NULL;
772 fra.me.REG[2] = NIT_NULL;
773 fra.me.REG[0] = p0;
774 fra.me.REG[1] = p1;
775 /* ./../lib/standard//collection//list.nit:154 */
776 fra.me.REG[2] = ATTR_standard___collection___list___List____head(fra.me.REG[0]);
777 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]);
778 /* ./../lib/standard//collection//list.nit:155 */
779 REGB0 = TAG_Bool(fra.me.REG[2]==NIT_NULL);
780 if (UNTAG_Bool(REGB0)) {
781 } else {
782 REGB1 = TAG_Bool(fra.me.REG[2]==NIT_NULL);
783 if (UNTAG_Bool(REGB1)) {
784 REGB1 = TAG_Bool(false);
785 REGB0 = REGB1;
786 } else {
787 REGB1 = CALL_standard___kernel___Object_____eqeq(fra.me.REG[2])(fra.me.REG[2], NIT_NULL);
788 REGB0 = REGB1;
789 }
790 }
791 REGB0 = TAG_Bool(!UNTAG_Bool(REGB0));
792 if (UNTAG_Bool(REGB0)) {
793 CALL_standard___collection___list___List___remove_node(fra.me.REG[0])(fra.me.REG[0], fra.me.REG[2]);
794 }
795 stack_frame_head = fra.me.prev;
796 return;
797 }
798 void standard___collection___list___List___remove_at(val_t p0, val_t p1){
799 struct {struct stack_frame_t me; val_t MORE_REG[1];} fra;
800 val_t REGB0;
801 val_t REGB1;
802 val_t tmp;
803 fra.me.prev = stack_frame_head; stack_frame_head = &fra.me;
804 fra.me.file = LOCATE_standard___collection___list;
805 fra.me.line = 158;
806 fra.me.meth = LOCATE_standard___collection___list___List___remove_at;
807 fra.me.has_broke = 0;
808 fra.me.REG_size = 2;
809 fra.me.REG[0] = NIT_NULL;
810 fra.me.REG[1] = NIT_NULL;
811 fra.me.REG[0] = p0;
812 REGB0 = p1;
813 /* ./../lib/standard//collection//list.nit:160 */
814 fra.me.REG[1] = CALL_standard___collection___list___List___get_node(fra.me.REG[0])(fra.me.REG[0], REGB0);
815 /* ./../lib/standard//collection//list.nit:161 */
816 REGB0 = TAG_Bool(fra.me.REG[1]==NIT_NULL);
817 if (UNTAG_Bool(REGB0)) {
818 } else {
819 REGB1 = TAG_Bool(fra.me.REG[1]==NIT_NULL);
820 if (UNTAG_Bool(REGB1)) {
821 REGB1 = TAG_Bool(false);
822 REGB0 = REGB1;
823 } else {
824 REGB1 = CALL_standard___kernel___Object_____eqeq(fra.me.REG[1])(fra.me.REG[1], NIT_NULL);
825 REGB0 = REGB1;
826 }
827 }
828 REGB0 = TAG_Bool(!UNTAG_Bool(REGB0));
829 if (UNTAG_Bool(REGB0)) {
830 CALL_standard___collection___list___List___remove_node(fra.me.REG[0])(fra.me.REG[0], fra.me.REG[1]);
831 }
832 stack_frame_head = fra.me.prev;
833 return;
834 }
835 void standard___collection___list___List___clear(val_t p0){
836 struct {struct stack_frame_t me;} fra;
837 val_t tmp;
838 fra.me.prev = stack_frame_head; stack_frame_head = &fra.me;
839 fra.me.file = LOCATE_standard___collection___list;
840 fra.me.line = 164;
841 fra.me.meth = LOCATE_standard___collection___list___List___clear;
842 fra.me.has_broke = 0;
843 fra.me.REG_size = 1;
844 fra.me.REG[0] = NIT_NULL;
845 fra.me.REG[0] = p0;
846 /* ./../lib/standard//collection//list.nit:166 */
847 ATTR_standard___collection___list___List____head(fra.me.REG[0]) = NIT_NULL;
848 /* ./../lib/standard//collection//list.nit:167 */
849 ATTR_standard___collection___list___List____tail(fra.me.REG[0]) = NIT_NULL;
850 stack_frame_head = fra.me.prev;
851 return;
852 }
853 val_t standard___collection___list___List___iterator(val_t p0){
854 struct {struct stack_frame_t me;} fra;
855 val_t tmp;
856 fra.me.prev = stack_frame_head; stack_frame_head = &fra.me;
857 fra.me.file = LOCATE_standard___collection___list;
858 fra.me.line = 171;
859 fra.me.meth = LOCATE_standard___collection___list___List___iterator;
860 fra.me.has_broke = 0;
861 fra.me.REG_size = 1;
862 fra.me.REG[0] = NIT_NULL;
863 fra.me.REG[0] = p0;
864 /* ./../lib/standard//collection//list.nit:171 */
865 fra.me.REG[0] = NEW_ListIterator_standard___collection___list___ListIterator___init(fra.me.REG[0]);
866 goto label1;
867 label1: while(0);
868 stack_frame_head = fra.me.prev;
869 return fra.me.REG[0];
870 }
871 void standard___collection___list___List___init(val_t p0, int* init_table){
872 int itpos0 = VAL2OBJ(p0)->vft[INIT_TABLE_POS_standard___collection___list___List].i;
873 struct {struct stack_frame_t me;} fra;
874 val_t tmp;
875 if (init_table[itpos0]) return;
876 fra.me.prev = stack_frame_head; stack_frame_head = &fra.me;
877 fra.me.file = LOCATE_standard___collection___list;
878 fra.me.line = 173;
879 fra.me.meth = LOCATE_standard___collection___list___List___init;
880 fra.me.has_broke = 0;
881 fra.me.REG_size = 1;
882 fra.me.REG[0] = NIT_NULL;
883 fra.me.REG[0] = p0;
884 stack_frame_head = fra.me.prev;
885 init_table[itpos0] = 1;
886 return;
887 }
888 void standard___collection___list___List___from(val_t p0, val_t p1, int* init_table){
889 int itpos1 = VAL2OBJ(p0)->vft[INIT_TABLE_POS_standard___collection___list___List].i;
890 struct {struct stack_frame_t me; val_t MORE_REG[1];} fra;
891 val_t tmp;
892 if (init_table[itpos1]) return;
893 fra.me.prev = stack_frame_head; stack_frame_head = &fra.me;
894 fra.me.file = LOCATE_standard___collection___list;
895 fra.me.line = 176;
896 fra.me.meth = LOCATE_standard___collection___list___List___from;
897 fra.me.has_broke = 0;
898 fra.me.REG_size = 2;
899 fra.me.REG[0] = NIT_NULL;
900 fra.me.REG[1] = NIT_NULL;
901 fra.me.REG[0] = p0;
902 fra.me.REG[1] = p1;
903 /* ./../lib/standard//collection//list.nit:177 */
904 CALL_standard___collection___abstract_collection___Sequence___append(fra.me.REG[0])(fra.me.REG[0], fra.me.REG[1]);
905 stack_frame_head = fra.me.prev;
906 init_table[itpos1] = 1;
907 return;
908 }
909 val_t standard___collection___list___List___get_node(val_t p0, val_t p1){
910 struct {struct stack_frame_t me; val_t MORE_REG[2];} fra;
911 val_t REGB0;
912 val_t REGB1;
913 val_t REGB2;
914 val_t tmp;
915 fra.me.prev = stack_frame_head; stack_frame_head = &fra.me;
916 fra.me.file = LOCATE_standard___collection___list;
917 fra.me.line = 185;
918 fra.me.meth = LOCATE_standard___collection___list___List___get_node;
919 fra.me.has_broke = 0;
920 fra.me.REG_size = 3;
921 fra.me.REG[0] = NIT_NULL;
922 fra.me.REG[1] = NIT_NULL;
923 fra.me.REG[2] = NIT_NULL;
924 fra.me.REG[0] = p0;
925 REGB0 = p1;
926 /* ./../lib/standard//collection//list.nit:188 */
927 fra.me.REG[0] = ATTR_standard___collection___list___List____head(fra.me.REG[0]);
928 /* ./../lib/standard//collection//list.nit:189 */
929 REGB1 = TAG_Int(0);
930 REGB2 = TAG_Bool(VAL_ISA(REGB1, VTCOLOR_standard___kernel___Comparable___OTHER(REGB0), VTID_standard___kernel___Comparable___OTHER(REGB0))) /*cast OTHER*/;
931 if (UNTAG_Bool(REGB2)) {
932 } else {
933 nit_abort("Cast failed", NULL, LOCATE_standard___kernel, 0);
934 }
935 /* ./../lib/standard//kernel.nit:232 */
936 REGB1 = TAG_Bool(UNTAG_Int(REGB0)<UNTAG_Int(REGB1));
937 /* ./../lib/standard//collection//list.nit:189 */
938 if (UNTAG_Bool(REGB1)) {
939 /* ./../lib/standard//collection//list.nit:190 */
940 fra.me.REG[1] = NIT_NULL;
941 goto label1;
942 }
943 /* ./../lib/standard//collection//list.nit:192 */
944 while(1) {
945 REGB1 = TAG_Bool(fra.me.REG[0]==NIT_NULL);
946 if (UNTAG_Bool(REGB1)) {
947 } else {
948 REGB2 = TAG_Bool(fra.me.REG[0]==NIT_NULL);
949 if (UNTAG_Bool(REGB2)) {
950 REGB2 = TAG_Bool(false);
951 REGB1 = REGB2;
952 } else {
953 REGB2 = CALL_standard___kernel___Object_____eqeq(fra.me.REG[0])(fra.me.REG[0], NIT_NULL);
954 REGB1 = REGB2;
955 }
956 }
957 REGB1 = TAG_Bool(!UNTAG_Bool(REGB1));
958 if (UNTAG_Bool(REGB1)) {
959 REGB1 = TAG_Int(0);
960 REGB2 = TAG_Bool(VAL_ISA(REGB1, VTCOLOR_standard___kernel___Comparable___OTHER(REGB0), VTID_standard___kernel___Comparable___OTHER(REGB0))) /*cast OTHER*/;
961 if (UNTAG_Bool(REGB2)) {
962 } else {
963 nit_abort("Cast failed", NULL, LOCATE_standard___kernel, 0);
964 }
965 /* ./../lib/standard//kernel.nit:234 */
966 REGB1 = TAG_Bool(UNTAG_Int(REGB0)>UNTAG_Int(REGB1));
967 } else {
968 /* ./../lib/standard//collection//list.nit:192 */
969 REGB2 = TAG_Bool(false);
970 REGB1 = REGB2;
971 }
972 if (UNTAG_Bool(REGB1)) {
973 /* ./../lib/standard//collection//list.nit:193 */
974 REGB1 = TAG_Bool(fra.me.REG[0]==NIT_NULL);
975 if (UNTAG_Bool(REGB1)) {
976 nit_abort("Reciever is null", NULL, LOCATE_standard___collection___list, 193);
977 }
978 fra.me.REG[2] = CALL_standard___collection___list___ListNode___next(fra.me.REG[0])(fra.me.REG[0]);
979 fra.me.REG[0] = fra.me.REG[2];
980 /* ./../lib/standard//collection//list.nit:194 */
981 REGB1 = TAG_Int(1);
982 /* ./../lib/standard//kernel.nit:237 */
983 REGB1 = TAG_Int(UNTAG_Int(REGB0)-UNTAG_Int(REGB1));
984 /* ./../lib/standard//collection//list.nit:194 */
985 REGB0 = REGB1;
986 } else {
987 /* ./../lib/standard//collection//list.nit:192 */
988 goto label2;
989 }
990 }
991 label2: while(0);
992 /* ./../lib/standard//collection//list.nit:196 */
993 fra.me.REG[1] = fra.me.REG[0];
994 goto label1;
995 label1: while(0);
996 stack_frame_head = fra.me.prev;
997 return fra.me.REG[1];
998 }
999 val_t standard___collection___list___List___search_node_after(val_t p0, val_t p1, val_t p2){
1000 struct {struct stack_frame_t me; val_t MORE_REG[2];} fra;
1001 val_t REGB0;
1002 val_t REGB1;
1003 val_t tmp;
1004 fra.me.prev = stack_frame_head; stack_frame_head = &fra.me;
1005 fra.me.file = LOCATE_standard___collection___list;
1006 fra.me.line = 199;
1007 fra.me.meth = LOCATE_standard___collection___list___List___search_node_after;
1008 fra.me.has_broke = 0;
1009 fra.me.REG_size = 3;
1010 fra.me.REG[0] = NIT_NULL;
1011 fra.me.REG[1] = NIT_NULL;
1012 fra.me.REG[2] = NIT_NULL;
1013 fra.me.REG[0] = p0;
1014 fra.me.REG[1] = p1;
1015 fra.me.REG[2] = p2;
1016 /* ./../lib/standard//collection//list.nit:203 */
1017 while(1) {
1018 REGB0 = TAG_Bool(fra.me.REG[2]==NIT_NULL);
1019 if (UNTAG_Bool(REGB0)) {
1020 } else {
1021 REGB1 = TAG_Bool(fra.me.REG[2]==NIT_NULL);
1022 if (UNTAG_Bool(REGB1)) {
1023 REGB1 = TAG_Bool(false);
1024 REGB0 = REGB1;
1025 } else {
1026 REGB1 = CALL_standard___kernel___Object_____eqeq(fra.me.REG[2])(fra.me.REG[2], NIT_NULL);
1027 REGB0 = REGB1;
1028 }
1029 }
1030 REGB0 = TAG_Bool(!UNTAG_Bool(REGB0));
1031 if (UNTAG_Bool(REGB0)) {
1032 REGB0 = TAG_Bool(fra.me.REG[2]==NIT_NULL);
1033 if (UNTAG_Bool(REGB0)) {
1034 nit_abort("Reciever is null", NULL, LOCATE_standard___collection___list, 203);
1035 }
1036 fra.me.REG[0] = CALL_standard___collection___abstract_collection___Container___item(fra.me.REG[2])(fra.me.REG[2]);
1037 REGB0 = TAG_Bool(IS_EQUAL_NN(fra.me.REG[0],fra.me.REG[1]));
1038 if (UNTAG_Bool(REGB0)) {
1039 } else {
1040 REGB1 = TAG_Bool(fra.me.REG[0]==NIT_NULL);
1041 if (UNTAG_Bool(REGB1)) {
1042 REGB1 = TAG_Bool(false);
1043 REGB0 = REGB1;
1044 } else {
1045 REGB1 = CALL_standard___kernel___Object_____eqeq(fra.me.REG[0])(fra.me.REG[0], fra.me.REG[1]);
1046 REGB0 = REGB1;
1047 }
1048 }
1049 REGB0 = TAG_Bool(!UNTAG_Bool(REGB0));
1050 } else {
1051 REGB1 = TAG_Bool(false);
1052 REGB0 = REGB1;
1053 }
1054 if (UNTAG_Bool(REGB0)) {
1055 REGB0 = TAG_Bool(fra.me.REG[2]==NIT_NULL);
1056 if (UNTAG_Bool(REGB0)) {
1057 nit_abort("Reciever is null", NULL, LOCATE_standard___collection___list, 203);
1058 }
1059 fra.me.REG[0] = CALL_standard___collection___list___ListNode___next(fra.me.REG[2])(fra.me.REG[2]);
1060 fra.me.REG[2] = fra.me.REG[0];
1061 } else {
1062 goto label1;
1063 }
1064 }
1065 label1: while(0);
1066 /* ./../lib/standard//collection//list.nit:204 */
1067 goto label2;
1068 label2: while(0);
1069 stack_frame_head = fra.me.prev;
1070 return fra.me.REG[2];
1071 }
1072 void standard___collection___list___List___remove_node(val_t p0, val_t p1){
1073 struct {struct stack_frame_t me; val_t MORE_REG[2];} fra;
1074 val_t REGB0;
1075 val_t REGB1;
1076 val_t tmp;
1077 fra.me.prev = stack_frame_head; stack_frame_head = &fra.me;
1078 fra.me.file = LOCATE_standard___collection___list;
1079 fra.me.line = 207;
1080 fra.me.meth = LOCATE_standard___collection___list___List___remove_node;
1081 fra.me.has_broke = 0;
1082 fra.me.REG_size = 3;
1083 fra.me.REG[0] = NIT_NULL;
1084 fra.me.REG[1] = NIT_NULL;
1085 fra.me.REG[2] = NIT_NULL;
1086 fra.me.REG[0] = p0;
1087 fra.me.REG[1] = p1;
1088 /* ./../lib/standard//collection//list.nit:210 */
1089 fra.me.REG[2] = CALL_standard___collection___list___ListNode___prev(fra.me.REG[1])(fra.me.REG[1]);
1090 REGB0 = TAG_Bool(fra.me.REG[2]==NIT_NULL);
1091 if (UNTAG_Bool(REGB0)) {
1092 } else {
1093 REGB1 = TAG_Bool(fra.me.REG[2]==NIT_NULL);
1094 if (UNTAG_Bool(REGB1)) {
1095 REGB1 = TAG_Bool(false);
1096 REGB0 = REGB1;
1097 } else {
1098 REGB1 = CALL_standard___kernel___Object_____eqeq(fra.me.REG[2])(fra.me.REG[2], NIT_NULL);
1099 REGB0 = REGB1;
1100 }
1101 }
1102 if (UNTAG_Bool(REGB0)) {
1103 /* ./../lib/standard//collection//list.nit:211 */
1104 fra.me.REG[2] = CALL_standard___collection___list___ListNode___next(fra.me.REG[1])(fra.me.REG[1]);
1105 ATTR_standard___collection___list___List____head(fra.me.REG[0]) = fra.me.REG[2];
1106 /* ./../lib/standard//collection//list.nit:212 */
1107 fra.me.REG[2] = CALL_standard___collection___list___ListNode___next(fra.me.REG[1])(fra.me.REG[1]);
1108 REGB0 = TAG_Bool(fra.me.REG[2]==NIT_NULL);
1109 if (UNTAG_Bool(REGB0)) {
1110 } else {
1111 REGB1 = TAG_Bool(fra.me.REG[2]==NIT_NULL);
1112 if (UNTAG_Bool(REGB1)) {
1113 REGB1 = TAG_Bool(false);
1114 REGB0 = REGB1;
1115 } else {
1116 REGB1 = CALL_standard___kernel___Object_____eqeq(fra.me.REG[2])(fra.me.REG[2], NIT_NULL);
1117 REGB0 = REGB1;
1118 }
1119 }
1120 if (UNTAG_Bool(REGB0)) {
1121 /* ./../lib/standard//collection//list.nit:213 */
1122 ATTR_standard___collection___list___List____tail(fra.me.REG[0]) = NIT_NULL;
1123 } else {
1124 /* ./../lib/standard//collection//list.nit:215 */
1125 fra.me.REG[2] = CALL_standard___collection___list___ListNode___next(fra.me.REG[1])(fra.me.REG[1]);
1126 REGB0 = TAG_Bool(fra.me.REG[2]==NIT_NULL);
1127 if (UNTAG_Bool(REGB0)) {
1128 nit_abort("Reciever is null", NULL, LOCATE_standard___collection___list, 215);
1129 }
1130 CALL_standard___collection___list___ListNode___prev__eq(fra.me.REG[2])(fra.me.REG[2], NIT_NULL);
1131 }
1132 } else {
1133 /* ./../lib/standard//collection//list.nit:217 */
1134 fra.me.REG[2] = CALL_standard___collection___list___ListNode___next(fra.me.REG[1])(fra.me.REG[1]);
1135 REGB0 = TAG_Bool(fra.me.REG[2]==NIT_NULL);
1136 if (UNTAG_Bool(REGB0)) {
1137 } else {
1138 REGB1 = TAG_Bool(fra.me.REG[2]==NIT_NULL);
1139 if (UNTAG_Bool(REGB1)) {
1140 REGB1 = TAG_Bool(false);
1141 REGB0 = REGB1;
1142 } else {
1143 REGB1 = CALL_standard___kernel___Object_____eqeq(fra.me.REG[2])(fra.me.REG[2], NIT_NULL);
1144 REGB0 = REGB1;
1145 }
1146 }
1147 if (UNTAG_Bool(REGB0)) {
1148 /* ./../lib/standard//collection//list.nit:218 */
1149 fra.me.REG[2] = CALL_standard___collection___list___ListNode___prev(fra.me.REG[1])(fra.me.REG[1]);
1150 ATTR_standard___collection___list___List____tail(fra.me.REG[0]) = fra.me.REG[2];
1151 /* ./../lib/standard//collection//list.nit:219 */
1152 fra.me.REG[2] = CALL_standard___collection___list___ListNode___prev(fra.me.REG[1])(fra.me.REG[1]);
1153 REGB0 = TAG_Bool(fra.me.REG[2]==NIT_NULL);
1154 if (UNTAG_Bool(REGB0)) {
1155 nit_abort("Reciever is null", NULL, LOCATE_standard___collection___list, 219);
1156 }
1157 CALL_standard___collection___list___ListNode___next__eq(fra.me.REG[2])(fra.me.REG[2], NIT_NULL);
1158 } else {
1159 /* ./../lib/standard//collection//list.nit:221 */
1160 fra.me.REG[2] = CALL_standard___collection___list___ListNode___prev(fra.me.REG[1])(fra.me.REG[1]);
1161 fra.me.REG[0] = CALL_standard___collection___list___ListNode___next(fra.me.REG[1])(fra.me.REG[1]);
1162 REGB0 = TAG_Bool(fra.me.REG[2]==NIT_NULL);
1163 if (UNTAG_Bool(REGB0)) {
1164 nit_abort("Reciever is null", NULL, LOCATE_standard___collection___list, 221);
1165 }
1166 CALL_standard___collection___list___ListNode___next__eq(fra.me.REG[2])(fra.me.REG[2], fra.me.REG[0]);
1167 /* ./../lib/standard//collection//list.nit:222 */
1168 fra.me.REG[0] = CALL_standard___collection___list___ListNode___next(fra.me.REG[1])(fra.me.REG[1]);
1169 fra.me.REG[1] = CALL_standard___collection___list___ListNode___prev(fra.me.REG[1])(fra.me.REG[1]);
1170 REGB0 = TAG_Bool(fra.me.REG[0]==NIT_NULL);
1171 if (UNTAG_Bool(REGB0)) {
1172 nit_abort("Reciever is null", NULL, LOCATE_standard___collection___list, 222);
1173 }
1174 CALL_standard___collection___list___ListNode___prev__eq(fra.me.REG[0])(fra.me.REG[0], fra.me.REG[1]);
1175 }
1176 }
1177 stack_frame_head = fra.me.prev;
1178 return;
1179 }
1180 void standard___collection___list___List___insert_before(val_t p0, val_t p1, val_t p2){
1181 struct {struct stack_frame_t me; val_t MORE_REG[3];} fra;
1182 val_t REGB0;
1183 val_t REGB1;
1184 val_t tmp;
1185 fra.me.prev = stack_frame_head; stack_frame_head = &fra.me;
1186 fra.me.file = LOCATE_standard___collection___list;
1187 fra.me.line = 226;
1188 fra.me.meth = LOCATE_standard___collection___list___List___insert_before;
1189 fra.me.has_broke = 0;
1190 fra.me.REG_size = 4;
1191 fra.me.REG[0] = NIT_NULL;
1192 fra.me.REG[1] = NIT_NULL;
1193 fra.me.REG[2] = NIT_NULL;
1194 fra.me.REG[3] = NIT_NULL;
1195 fra.me.REG[0] = p0;
1196 fra.me.REG[1] = p1;
1197 fra.me.REG[2] = p2;
1198 /* ./../lib/standard//collection//list.nit:228 */
1199 fra.me.REG[1] = NEW_ListNode_standard___collection___list___ListNode___init(fra.me.REG[1]);
1200 /* ./../lib/standard//collection//list.nit:229 */
1201 fra.me.REG[3] = CALL_standard___collection___list___ListNode___prev(fra.me.REG[2])(fra.me.REG[2]);
1202 /* ./../lib/standard//collection//list.nit:230 */
1203 REGB0 = TAG_Bool(fra.me.REG[3]==NIT_NULL);
1204 if (UNTAG_Bool(REGB0)) {
1205 } else {
1206 REGB1 = TAG_Bool(fra.me.REG[3]==NIT_NULL);
1207 if (UNTAG_Bool(REGB1)) {
1208 REGB1 = TAG_Bool(false);
1209 REGB0 = REGB1;
1210 } else {
1211 REGB1 = CALL_standard___kernel___Object_____eqeq(fra.me.REG[3])(fra.me.REG[3], NIT_NULL);
1212 REGB0 = REGB1;
1213 }
1214 }
1215 if (UNTAG_Bool(REGB0)) {
1216 /* ./../lib/standard//collection//list.nit:231 */
1217 ATTR_standard___collection___list___List____head(fra.me.REG[0]) = fra.me.REG[1];
1218 } else {
1219 /* ./../lib/standard//collection//list.nit:233 */
1220 REGB0 = TAG_Bool(fra.me.REG[3]==NIT_NULL);
1221 if (UNTAG_Bool(REGB0)) {
1222 nit_abort("Reciever is null", NULL, LOCATE_standard___collection___list, 233);
1223 }
1224 CALL_standard___collection___list___ListNode___next__eq(fra.me.REG[3])(fra.me.REG[3], fra.me.REG[1]);
1225 }
1226 /* ./../lib/standard//collection//list.nit:235 */
1227 CALL_standard___collection___list___ListNode___prev__eq(fra.me.REG[1])(fra.me.REG[1], fra.me.REG[3]);
1228 /* ./../lib/standard//collection//list.nit:236 */
1229 CALL_standard___collection___list___ListNode___next__eq(fra.me.REG[1])(fra.me.REG[1], fra.me.REG[2]);
1230 /* ./../lib/standard//collection//list.nit:237 */
1231 CALL_standard___collection___list___ListNode___prev__eq(fra.me.REG[2])(fra.me.REG[2], fra.me.REG[1]);
1232 stack_frame_head = fra.me.prev;
1233 return;
1234 }
1235 val_t standard___collection___list___ListIterator___item(val_t p0){
1236 struct {struct stack_frame_t me;} fra;
1237 val_t REGB0;
1238 val_t tmp;
1239 fra.me.prev = stack_frame_head; stack_frame_head = &fra.me;
1240 fra.me.file = LOCATE_standard___collection___list;
1241 fra.me.line = 244;
1242 fra.me.meth = LOCATE_standard___collection___list___ListIterator___item;
1243 fra.me.has_broke = 0;
1244 fra.me.REG_size = 1;
1245 fra.me.REG[0] = NIT_NULL;
1246 fra.me.REG[0] = p0;
1247 /* ./../lib/standard//collection//list.nit:244 */
1248 fra.me.REG[0] = ATTR_standard___collection___list___ListIterator____node(fra.me.REG[0]);
1249 REGB0 = TAG_Bool(fra.me.REG[0]==NIT_NULL);
1250 if (UNTAG_Bool(REGB0)) {
1251 nit_abort("Reciever is null", NULL, LOCATE_standard___collection___list, 244);
1252 }
1253 fra.me.REG[0] = CALL_standard___collection___abstract_collection___Container___item(fra.me.REG[0])(fra.me.REG[0]);
1254 goto label1;
1255 label1: while(0);
1256 stack_frame_head = fra.me.prev;
1257 return fra.me.REG[0];
1258 }
1259 void standard___collection___list___ListIterator___item__eq(val_t p0, val_t p1){
1260 struct {struct stack_frame_t me; val_t MORE_REG[1];} fra;
1261 val_t REGB0;
1262 val_t tmp;
1263 fra.me.prev = stack_frame_head; stack_frame_head = &fra.me;
1264 fra.me.file = LOCATE_standard___collection___list;
1265 fra.me.line = 246;
1266 fra.me.meth = LOCATE_standard___collection___list___ListIterator___item__eq;
1267 fra.me.has_broke = 0;
1268 fra.me.REG_size = 2;
1269 fra.me.REG[0] = NIT_NULL;
1270 fra.me.REG[1] = NIT_NULL;
1271 fra.me.REG[0] = p0;
1272 fra.me.REG[1] = p1;
1273 /* ./../lib/standard//collection//list.nit:246 */
1274 fra.me.REG[0] = ATTR_standard___collection___list___ListIterator____node(fra.me.REG[0]);
1275 REGB0 = TAG_Bool(fra.me.REG[0]==NIT_NULL);
1276 if (UNTAG_Bool(REGB0)) {
1277 nit_abort("Reciever is null", NULL, LOCATE_standard___collection___list, 246);
1278 }
1279 CALL_standard___collection___abstract_collection___Container___item__eq(fra.me.REG[0])(fra.me.REG[0], fra.me.REG[1]);
1280 stack_frame_head = fra.me.prev;
1281 return;
1282 }
1283 val_t standard___collection___list___ListIterator___is_ok(val_t p0){
1284 struct {struct stack_frame_t me;} fra;
1285 val_t REGB0;
1286 val_t REGB1;
1287 val_t tmp;
1288 fra.me.prev = stack_frame_head; stack_frame_head = &fra.me;
1289 fra.me.file = LOCATE_standard___collection___list;
1290 fra.me.line = 248;
1291 fra.me.meth = LOCATE_standard___collection___list___ListIterator___is_ok;
1292 fra.me.has_broke = 0;
1293 fra.me.REG_size = 1;
1294 fra.me.REG[0] = NIT_NULL;
1295 fra.me.REG[0] = p0;
1296 /* ./../lib/standard//collection//list.nit:248 */
1297 fra.me.REG[0] = ATTR_standard___collection___list___ListIterator____node(fra.me.REG[0]);
1298 REGB0 = TAG_Bool(fra.me.REG[0]==NIT_NULL);
1299 if (UNTAG_Bool(REGB0)) {
1300 } else {
1301 REGB1 = TAG_Bool(fra.me.REG[0]==NIT_NULL);
1302 if (UNTAG_Bool(REGB1)) {
1303 REGB1 = TAG_Bool(false);
1304 REGB0 = REGB1;
1305 } else {
1306 REGB1 = CALL_standard___kernel___Object_____eqeq(fra.me.REG[0])(fra.me.REG[0], NIT_NULL);
1307 REGB0 = REGB1;
1308 }
1309 }
1310 REGB0 = TAG_Bool(!UNTAG_Bool(REGB0));
1311 goto label1;
1312 label1: while(0);
1313 stack_frame_head = fra.me.prev;
1314 return REGB0;
1315 }
1316 void standard___collection___list___ListIterator___next(val_t p0){
1317 struct {struct stack_frame_t me; val_t MORE_REG[1];} fra;
1318 val_t REGB0;
1319 val_t REGB1;
1320 val_t tmp;
1321 fra.me.prev = stack_frame_head; stack_frame_head = &fra.me;
1322 fra.me.file = LOCATE_standard___collection___list;
1323 fra.me.line = 250;
1324 fra.me.meth = LOCATE_standard___collection___list___ListIterator___next;
1325 fra.me.has_broke = 0;
1326 fra.me.REG_size = 2;
1327 fra.me.REG[0] = NIT_NULL;
1328 fra.me.REG[1] = NIT_NULL;
1329 fra.me.REG[0] = p0;
1330 /* ./../lib/standard//collection//list.nit:252 */
1331 fra.me.REG[1] = ATTR_standard___collection___list___ListIterator____node(fra.me.REG[0]);
1332 REGB0 = TAG_Bool(fra.me.REG[1]==NIT_NULL);
1333 if (UNTAG_Bool(REGB0)) {
1334 nit_abort("Reciever is null", NULL, LOCATE_standard___collection___list, 252);
1335 }
1336 fra.me.REG[1] = CALL_standard___collection___list___ListNode___next(fra.me.REG[1])(fra.me.REG[1]);
1337 ATTR_standard___collection___list___ListIterator____node(fra.me.REG[0]) = fra.me.REG[1];
1338 /* ./../lib/standard//collection//list.nit:253 */
1339 REGB0 = ATTR_standard___collection___list___ListIterator____index(fra.me.REG[0]);
1340 REGB1 = TAG_Int(1);
1341 /* ./../lib/standard//kernel.nit:235 */
1342 REGB1 = TAG_Int(UNTAG_Int(REGB0)+UNTAG_Int(REGB1));
1343 /* ./../lib/standard//collection//list.nit:253 */
1344 ATTR_standard___collection___list___ListIterator____index(fra.me.REG[0]) = REGB1;
1345 stack_frame_head = fra.me.prev;
1346 return;
1347 }
1348 void standard___collection___list___ListIterator___init(val_t p0, val_t p1, int* init_table){
1349 int itpos2 = VAL2OBJ(p0)->vft[INIT_TABLE_POS_standard___collection___list___ListIterator].i;
1350 struct {struct stack_frame_t me; val_t MORE_REG[1];} fra;
1351 val_t REGB0;
1352 val_t tmp;
1353 if (init_table[itpos2]) return;
1354 fra.me.prev = stack_frame_head; stack_frame_head = &fra.me;
1355 fra.me.file = LOCATE_standard___collection___list;
1356 fra.me.line = 256;
1357 fra.me.meth = LOCATE_standard___collection___list___ListIterator___init;
1358 fra.me.has_broke = 0;
1359 fra.me.REG_size = 2;
1360 fra.me.REG[0] = NIT_NULL;
1361 fra.me.REG[1] = NIT_NULL;
1362 fra.me.REG[0] = p0;
1363 fra.me.REG[1] = p1;
1364 /* ./../lib/standard//collection//list.nit:259 */
1365 ATTR_standard___collection___list___ListIterator____list(fra.me.REG[0]) = fra.me.REG[1];
1366 /* ./../lib/standard//collection//list.nit:260 */
1367 fra.me.REG[1] = ATTR_standard___collection___list___List____head(fra.me.REG[1]);
1368 ATTR_standard___collection___list___ListIterator____node(fra.me.REG[0]) = fra.me.REG[1];
1369 /* ./../lib/standard//collection//list.nit:261 */
1370 REGB0 = TAG_Int(0);
1371 ATTR_standard___collection___list___ListIterator____index(fra.me.REG[0]) = REGB0;
1372 stack_frame_head = fra.me.prev;
1373 init_table[itpos2] = 1;
1374 return;
1375 }
1376 val_t standard___collection___list___ListIterator___index(val_t p0){
1377 struct {struct stack_frame_t me;} fra;
1378 val_t REGB0;
1379 val_t tmp;
1380 fra.me.prev = stack_frame_head; stack_frame_head = &fra.me;
1381 fra.me.file = LOCATE_standard___collection___list;
1382 fra.me.line = 270;
1383 fra.me.meth = LOCATE_standard___collection___list___ListIterator___index;
1384 fra.me.has_broke = 0;
1385 fra.me.REG_size = 1;
1386 fra.me.REG[0] = NIT_NULL;
1387 fra.me.REG[0] = p0;
1388 /* ./../lib/standard//collection//list.nit:270 */
1389 REGB0 = TAG_Bool(ATTR_standard___collection___list___ListIterator____index(fra.me.REG[0])!=NIT_NULL);
1390 if (UNTAG_Bool(REGB0)) {
1391 } else {
1392 nit_abort("Uninitialized attribute %s", "_index", LOCATE_standard___collection___list, 270);
1393 }
1394 REGB0 = ATTR_standard___collection___list___ListIterator____index(fra.me.REG[0]);
1395 stack_frame_head = fra.me.prev;
1396 return REGB0;
1397 }
1398 void standard___collection___list___ListIterator___delete(val_t p0){
1399 struct {struct stack_frame_t me; val_t MORE_REG[2];} fra;
1400 val_t REGB0;
1401 val_t tmp;
1402 fra.me.prev = stack_frame_head; stack_frame_head = &fra.me;
1403 fra.me.file = LOCATE_standard___collection___list;
1404 fra.me.line = 273;
1405 fra.me.meth = LOCATE_standard___collection___list___ListIterator___delete;
1406 fra.me.has_broke = 0;
1407 fra.me.REG_size = 3;
1408 fra.me.REG[0] = NIT_NULL;
1409 fra.me.REG[1] = NIT_NULL;
1410 fra.me.REG[2] = NIT_NULL;
1411 fra.me.REG[0] = p0;
1412 /* ./../lib/standard//collection//list.nit:273 */
1413 fra.me.REG[1] = fra.me.REG[0];
1414 /* ./../lib/standard//collection//list.nit:276 */
1415 REGB0 = TAG_Bool(ATTR_standard___collection___list___ListIterator____list(fra.me.REG[1])!=NIT_NULL);
1416 if (UNTAG_Bool(REGB0)) {
1417 } else {
1418 nit_abort("Uninitialized attribute %s", "_list", LOCATE_standard___collection___list, 276);
1419 }
1420 fra.me.REG[2] = ATTR_standard___collection___list___ListIterator____list(fra.me.REG[1]);
1421 fra.me.REG[1] = ATTR_standard___collection___list___ListIterator____node(fra.me.REG[1]);
1422 REGB0 = TAG_Bool(fra.me.REG[1]!=NIT_NULL);
1423 if (UNTAG_Bool(REGB0)) {
1424 } else {
1425 nit_abort("Cast failed", NULL, LOCATE_standard___collection___list, 276);
1426 }
1427 CALL_standard___collection___list___List___remove_node(fra.me.REG[2])(fra.me.REG[2], fra.me.REG[1]);
1428 stack_frame_head = fra.me.prev;
1429 return;
1430 }
1431 void standard___collection___list___ListIterator___insert_before(val_t p0, val_t p1){
1432 struct {struct stack_frame_t me; val_t MORE_REG[3];} fra;
1433 val_t REGB0;
1434 val_t tmp;
1435 fra.me.prev = stack_frame_head; stack_frame_head = &fra.me;
1436 fra.me.file = LOCATE_standard___collection___list;
1437 fra.me.line = 279;
1438 fra.me.meth = LOCATE_standard___collection___list___ListIterator___insert_before;
1439 fra.me.has_broke = 0;
1440 fra.me.REG_size = 4;
1441 fra.me.REG[0] = NIT_NULL;
1442 fra.me.REG[1] = NIT_NULL;
1443 fra.me.REG[2] = NIT_NULL;
1444 fra.me.REG[3] = NIT_NULL;
1445 fra.me.REG[0] = p0;
1446 fra.me.REG[1] = p1;
1447 /* ./../lib/standard//collection//list.nit:279 */
1448 fra.me.REG[2] = fra.me.REG[0];
1449 /* ./../lib/standard//collection//list.nit:282 */
1450 REGB0 = TAG_Bool(ATTR_standard___collection___list___ListIterator____list(fra.me.REG[2])!=NIT_NULL);
1451 if (UNTAG_Bool(REGB0)) {
1452 } else {
1453 nit_abort("Uninitialized attribute %s", "_list", LOCATE_standard___collection___list, 282);
1454 }
1455 fra.me.REG[3] = ATTR_standard___collection___list___ListIterator____list(fra.me.REG[2]);
1456 fra.me.REG[2] = ATTR_standard___collection___list___ListIterator____node(fra.me.REG[2]);
1457 REGB0 = TAG_Bool(fra.me.REG[2]!=NIT_NULL);
1458 if (UNTAG_Bool(REGB0)) {
1459 } else {
1460 nit_abort("Cast failed", NULL, LOCATE_standard___collection___list, 282);
1461 }
1462 CALL_standard___collection___list___List___insert_before(fra.me.REG[3])(fra.me.REG[3], fra.me.REG[1], fra.me.REG[2]);
1463 stack_frame_head = fra.me.prev;
1464 return;
1465 }
1466 void standard___collection___list___ListNode___init(val_t p0, val_t p1, int* init_table){
1467 int itpos3 = VAL2OBJ(p0)->vft[INIT_TABLE_POS_standard___collection___list___ListNode].i;
1468 struct {struct stack_frame_t me; val_t MORE_REG[3];} fra;
1469 val_t tmp;
1470 if (init_table[itpos3]) return;
1471 fra.me.prev = stack_frame_head; stack_frame_head = &fra.me;
1472 fra.me.file = LOCATE_standard___collection___list;
1473 fra.me.line = 289;
1474 fra.me.meth = LOCATE_standard___collection___list___ListNode___init;
1475 fra.me.has_broke = 0;
1476 fra.me.REG_size = 4;
1477 fra.me.REG[0] = NIT_NULL;
1478 fra.me.REG[1] = NIT_NULL;
1479 fra.me.REG[2] = NIT_NULL;
1480 fra.me.REG[3] = NIT_NULL;
1481 fra.me.REG[0] = p0;
1482 fra.me.REG[1] = p1;
1483 /* ./../lib/standard//collection//list.nit:289 */
1484 fra.me.REG[2] = fra.me.REG[0];
1485 fra.me.REG[3] = fra.me.REG[1];
1486 CALL_standard___collection___abstract_collection___Container___init(fra.me.REG[0])(fra.me.REG[0], fra.me.REG[1], init_table);
1487 /* ./../lib/standard//collection//list.nit:291 */
1488 CALL_standard___collection___abstract_collection___Container___item__eq(fra.me.REG[2])(fra.me.REG[2], fra.me.REG[3]);
1489 stack_frame_head = fra.me.prev;
1490 init_table[itpos3] = 1;
1491 return;
1492 }
1493 val_t standard___collection___list___ListNode___next(val_t p0){
1494 struct {struct stack_frame_t me;} fra;
1495 val_t tmp;
1496 fra.me.prev = stack_frame_head; stack_frame_head = &fra.me;
1497 fra.me.file = LOCATE_standard___collection___list;
1498 fra.me.line = 294;
1499 fra.me.meth = LOCATE_standard___collection___list___ListNode___next;
1500 fra.me.has_broke = 0;
1501 fra.me.REG_size = 1;
1502 fra.me.REG[0] = NIT_NULL;
1503 fra.me.REG[0] = p0;
1504 /* ./../lib/standard//collection//list.nit:294 */
1505 fra.me.REG[0] = ATTR_standard___collection___list___ListNode____next(fra.me.REG[0]);
1506 stack_frame_head = fra.me.prev;
1507 return fra.me.REG[0];
1508 }
1509 void standard___collection___list___ListNode___next__eq(val_t p0, val_t p1){
1510 struct {struct stack_frame_t me; val_t MORE_REG[1];} fra;
1511 val_t tmp;
1512 fra.me.prev = stack_frame_head; stack_frame_head = &fra.me;
1513 fra.me.file = LOCATE_standard___collection___list;
1514 fra.me.line = 294;
1515 fra.me.meth = LOCATE_standard___collection___list___ListNode___next__eq;
1516 fra.me.has_broke = 0;
1517 fra.me.REG_size = 2;
1518 fra.me.REG[0] = NIT_NULL;
1519 fra.me.REG[1] = NIT_NULL;
1520 fra.me.REG[0] = p0;
1521 fra.me.REG[1] = p1;
1522 /* ./../lib/standard//collection//list.nit:294 */
1523 ATTR_standard___collection___list___ListNode____next(fra.me.REG[0]) = fra.me.REG[1];
1524 stack_frame_head = fra.me.prev;
1525 return;
1526 }
1527 val_t standard___collection___list___ListNode___prev(val_t p0){
1528 struct {struct stack_frame_t me;} fra;
1529 val_t tmp;
1530 fra.me.prev = stack_frame_head; stack_frame_head = &fra.me;
1531 fra.me.file = LOCATE_standard___collection___list;
1532 fra.me.line = 297;
1533 fra.me.meth = LOCATE_standard___collection___list___ListNode___prev;
1534 fra.me.has_broke = 0;
1535 fra.me.REG_size = 1;
1536 fra.me.REG[0] = NIT_NULL;
1537 fra.me.REG[0] = p0;
1538 /* ./../lib/standard//collection//list.nit:297 */
1539 fra.me.REG[0] = ATTR_standard___collection___list___ListNode____prev(fra.me.REG[0]);
1540 stack_frame_head = fra.me.prev;
1541 return fra.me.REG[0];
1542 }
1543 void standard___collection___list___ListNode___prev__eq(val_t p0, val_t p1){
1544 struct {struct stack_frame_t me; val_t MORE_REG[1];} fra;
1545 val_t tmp;
1546 fra.me.prev = stack_frame_head; stack_frame_head = &fra.me;
1547 fra.me.file = LOCATE_standard___collection___list;
1548 fra.me.line = 297;
1549 fra.me.meth = LOCATE_standard___collection___list___ListNode___prev__eq;
1550 fra.me.has_broke = 0;
1551 fra.me.REG_size = 2;
1552 fra.me.REG[0] = NIT_NULL;
1553 fra.me.REG[1] = NIT_NULL;
1554 fra.me.REG[0] = p0;
1555 fra.me.REG[1] = p1;
1556 /* ./../lib/standard//collection//list.nit:297 */
1557 ATTR_standard___collection___list___ListNode____prev(fra.me.REG[0]) = fra.me.REG[1];
1558 stack_frame_head = fra.me.prev;
1559 return;
1560 }