nitc: let CC, CXX and NO_STACKTRACE use env value
[nit.git] / c_src / core__ropes.sep.2.c
1 #include "core__ropes.sep.0.h"
2 /* method ropes#RopeChars#reverse_iterator_from for (self: RopeChars, Int): IndexedIterator[Char] */
3 val* core__ropes___core__ropes__RopeChars___core__abstract_collection__SequenceRead__reverse_iterator_from(val* self, long p0) {
4 val* var /* : IndexedIterator[Char] */;
5 long var_i /* var i: Int */;
6 val* var1 /* : RopeCharReverseIterator */;
7 val* var2 /* : Text */;
8 val* var4 /* : Text */;
9 var_i = p0;
10 var1 = NEW_core__ropes__RopeCharReverseIterator(&type_core__ropes__RopeCharReverseIterator);
11 {
12 { /* Inline abstract_text#StringCharView#target (self) on <self:RopeChars> */
13 var4 = self->attrs[COLOR_core__abstract_text__StringCharView___target].val; /* _target on <self:RopeChars> */
14 if (unlikely(var4 == NULL)) {
15 PRINT_ERROR("Runtime error: %s", "Uninitialized attribute _target");
16 PRINT_ERROR(" (%s:%d)\n", FILE_core__abstract_text, 1138);
17 fatal_exit(1);
18 }
19 var2 = var4;
20 RET_LABEL3:(void)0;
21 }
22 }
23 {
24 core__ropes___core__ropes__RopeCharReverseIterator___from(var1, var2, var_i); /* Direct call ropes#RopeCharReverseIterator#from on <var1:RopeCharReverseIterator>*/
25 }
26 var = var1;
27 goto RET_LABEL;
28 RET_LABEL:;
29 return var;
30 }
31 /* method ropes#RopeBytes#[] for (self: RopeBytes, Int): Byte */
32 unsigned char core__ropes___core__ropes__RopeBytes___core__abstract_collection__SequenceRead___91d_93d(val* self, long p0) {
33 unsigned char var /* : Byte */;
34 long var_i /* var i: Int */;
35 val* var1 /* : Text */;
36 val* var3 /* : Text */;
37 val* var_nod /* var nod: String */;
38 short int var4 /* : Bool */;
39 int cltype;
40 int idtype;
41 char* var5 /* : NativeString */;
42 unsigned char var6 /* : Byte */;
43 unsigned char var8 /* : Byte */;
44 short int var9 /* : Bool */;
45 int cltype10;
46 int idtype11;
47 short int var12 /* : Bool */;
48 val* var13 /* : String */;
49 val* var_lft /* var lft: String */;
50 long var14 /* : Int */;
51 short int var15 /* : Bool */;
52 short int var17 /* : Bool */;
53 int cltype18;
54 int idtype19;
55 const char* var_class_name;
56 short int var20 /* : Bool */;
57 val* var21 /* : String */;
58 var_i = p0;
59 {
60 { /* Inline abstract_text#StringByteView#target (self) on <self:RopeBytes> */
61 var3 = self->attrs[COLOR_core__abstract_text__StringByteView___target].val; /* _target on <self:RopeBytes> */
62 if (unlikely(var3 == NULL)) {
63 PRINT_ERROR("Runtime error: %s", "Uninitialized attribute _target");
64 PRINT_ERROR(" (%s:%d)\n", FILE_core__abstract_text, 1156);
65 fatal_exit(1);
66 }
67 var1 = var3;
68 RET_LABEL2:(void)0;
69 }
70 }
71 var_nod = var1;
72 for(;;) {
73 /* <var_nod:String> isa FlatString */
74 cltype = type_core__FlatString.color;
75 idtype = type_core__FlatString.id;
76 if(cltype >= var_nod->type->table_size) {
77 var4 = 0;
78 } else {
79 var4 = var_nod->type->type_table[cltype] == idtype;
80 }
81 if (var4){
82 var5 = var_nod->attrs[COLOR_core__abstract_text__FlatText___items].str; /* _items on <var_nod:String(FlatString)> */
83 {
84 { /* Inline native#NativeString#[] (var5,var_i) on <var5:NativeString> */
85 var8 = (unsigned char)((int)var5[var_i]);
86 var6 = var8;
87 goto RET_LABEL7;
88 RET_LABEL7:(void)0;
89 }
90 }
91 var = var6;
92 goto RET_LABEL;
93 } else {
94 }
95 /* <var_nod:String> isa Concat */
96 cltype10 = type_core__ropes__Concat.color;
97 idtype11 = type_core__ropes__Concat.id;
98 if(cltype10 >= var_nod->type->table_size) {
99 var9 = 0;
100 } else {
101 var9 = var_nod->type->type_table[cltype10] == idtype11;
102 }
103 var12 = !var9;
104 if (var12){
105 PRINT_ERROR("Runtime error: %s", "Aborted");
106 PRINT_ERROR(" (%s:%d)\n", FILE_core__ropes, 991);
107 fatal_exit(1);
108 } else {
109 }
110 var13 = var_nod->attrs[COLOR_core__ropes__Concat___left].val; /* _left on <var_nod:String(Concat)> */
111 if (unlikely(var13 == NULL)) {
112 PRINT_ERROR("Runtime error: %s", "Uninitialized attribute _left");
113 PRINT_ERROR(" (%s:%d)\n", FILE_core__ropes, 992);
114 fatal_exit(1);
115 }
116 var_lft = var13;
117 {
118 var14 = ((long(*)(val* self))(var_lft->class->vft[COLOR_core__abstract_text__Text__bytelen]))(var_lft); /* bytelen on <var_lft:String>*/
119 }
120 {
121 { /* Inline kernel#Int#>= (var14,var_i) on <var14:Int> */
122 /* Covariant cast for argument 0 (i) <var_i:Int> isa OTHER */
123 /* <var_i:Int> isa OTHER */
124 var17 = 1; /* easy <var_i:Int> isa OTHER*/
125 if (unlikely(!var17)) {
126 var_class_name = type_core__Int.name;
127 PRINT_ERROR("Runtime error: Cast failed. Expected `%s`, got `%s`", "OTHER", var_class_name);
128 PRINT_ERROR(" (%s:%d)\n", FILE_core__kernel, 729);
129 fatal_exit(1);
130 }
131 var20 = var14 >= var_i;
132 var15 = var20;
133 goto RET_LABEL16;
134 RET_LABEL16:(void)0;
135 }
136 }
137 if (var15){
138 var21 = var_nod->attrs[COLOR_core__ropes__Concat___right].val; /* _right on <var_nod:String(Concat)> */
139 if (unlikely(var21 == NULL)) {
140 PRINT_ERROR("Runtime error: %s", "Uninitialized attribute _right");
141 PRINT_ERROR(" (%s:%d)\n", FILE_core__ropes, 994);
142 fatal_exit(1);
143 }
144 var_nod = var21;
145 } else {
146 var_nod = var_lft;
147 }
148 }
149 RET_LABEL:;
150 return var;
151 }
152 /* method ropes#RopeBytes#[] for (self: SequenceRead[nullable Object], Int): nullable Object */
153 val* VIRTUAL_core__ropes___core__ropes__RopeBytes___core__abstract_collection__SequenceRead___91d_93d(val* self, long p0) {
154 val* var /* : nullable Object */;
155 unsigned char var1 /* : Byte */;
156 val* var2 /* : nullable Object */;
157 var1 = core__ropes___core__ropes__RopeBytes___core__abstract_collection__SequenceRead___91d_93d(self, p0);
158 var2 = BOX_core__Byte(var1); /* autobox from Byte to nullable Object */
159 var = var2;
160 RET_LABEL:;
161 return var;
162 }
163 /* method ropes#RopeBytes#iterator_from for (self: RopeBytes, Int): IndexedIterator[Byte] */
164 val* core__ropes___core__ropes__RopeBytes___core__abstract_collection__SequenceRead__iterator_from(val* self, long p0) {
165 val* var /* : IndexedIterator[Byte] */;
166 long var_i /* var i: Int */;
167 val* var1 /* : RopeByteIterator */;
168 val* var2 /* : Text */;
169 val* var4 /* : Text */;
170 var_i = p0;
171 var1 = NEW_core__ropes__RopeByteIterator(&type_core__ropes__RopeByteIterator);
172 {
173 { /* Inline abstract_text#StringByteView#target (self) on <self:RopeBytes> */
174 var4 = self->attrs[COLOR_core__abstract_text__StringByteView___target].val; /* _target on <self:RopeBytes> */
175 if (unlikely(var4 == NULL)) {
176 PRINT_ERROR("Runtime error: %s", "Uninitialized attribute _target");
177 PRINT_ERROR(" (%s:%d)\n", FILE_core__abstract_text, 1156);
178 fatal_exit(1);
179 }
180 var2 = var4;
181 RET_LABEL3:(void)0;
182 }
183 }
184 {
185 core__ropes___core__ropes__RopeByteIterator___from(var1, var2, var_i); /* Direct call ropes#RopeByteIterator#from on <var1:RopeByteIterator>*/
186 }
187 var = var1;
188 goto RET_LABEL;
189 RET_LABEL:;
190 return var;
191 }
192 /* method ropes#RopeBytes#reverse_iterator_from for (self: RopeBytes, Int): IndexedIterator[Byte] */
193 val* core__ropes___core__ropes__RopeBytes___core__abstract_collection__SequenceRead__reverse_iterator_from(val* self, long p0) {
194 val* var /* : IndexedIterator[Byte] */;
195 long var_i /* var i: Int */;
196 val* var1 /* : RopeByteReverseIterator */;
197 val* var2 /* : Text */;
198 val* var4 /* : Text */;
199 var_i = p0;
200 var1 = NEW_core__ropes__RopeByteReverseIterator(&type_core__ropes__RopeByteReverseIterator);
201 {
202 { /* Inline abstract_text#StringByteView#target (self) on <self:RopeBytes> */
203 var4 = self->attrs[COLOR_core__abstract_text__StringByteView___target].val; /* _target on <self:RopeBytes> */
204 if (unlikely(var4 == NULL)) {
205 PRINT_ERROR("Runtime error: %s", "Uninitialized attribute _target");
206 PRINT_ERROR(" (%s:%d)\n", FILE_core__abstract_text, 1156);
207 fatal_exit(1);
208 }
209 var2 = var4;
210 RET_LABEL3:(void)0;
211 }
212 }
213 {
214 core__ropes___core__ropes__RopeByteReverseIterator___from(var1, var2, var_i); /* Direct call ropes#RopeByteReverseIterator#from on <var1:RopeByteReverseIterator>*/
215 }
216 var = var1;
217 goto RET_LABEL;
218 RET_LABEL:;
219 return var;
220 }
221 /* method ropes#RopeBufferCharIterator#sit for (self: RopeBufferCharIterator): IndexedIterator[Char] */
222 val* core___core__RopeBufferCharIterator___sit(val* self) {
223 val* var /* : IndexedIterator[Char] */;
224 val* var1 /* : IndexedIterator[Char] */;
225 var1 = self->attrs[COLOR_core__ropes__RopeBufferCharIterator___sit].val; /* _sit on <self:RopeBufferCharIterator> */
226 if (unlikely(var1 == NULL)) {
227 PRINT_ERROR("Runtime error: %s", "Uninitialized attribute _sit");
228 PRINT_ERROR(" (%s:%d)\n", FILE_core__ropes, 1011);
229 fatal_exit(1);
230 }
231 var = var1;
232 RET_LABEL:;
233 return var;
234 }
235 /* method ropes#RopeBufferCharIterator#sit= for (self: RopeBufferCharIterator, IndexedIterator[Char]) */
236 void core___core__RopeBufferCharIterator___sit_61d(val* self, val* p0) {
237 self->attrs[COLOR_core__ropes__RopeBufferCharIterator___sit].val = p0; /* _sit on <self:RopeBufferCharIterator> */
238 RET_LABEL:;
239 }
240 /* method ropes#RopeBufferCharIterator#index for (self: RopeBufferCharIterator): Int */
241 long core___core__RopeBufferCharIterator___core__abstract_collection__IndexedIterator__index(val* self) {
242 long var /* : Int */;
243 val* var1 /* : IndexedIterator[Char] */;
244 val* var3 /* : IndexedIterator[Char] */;
245 long var4 /* : Int */;
246 {
247 { /* Inline ropes#RopeBufferCharIterator#sit (self) on <self:RopeBufferCharIterator> */
248 var3 = self->attrs[COLOR_core__ropes__RopeBufferCharIterator___sit].val; /* _sit on <self:RopeBufferCharIterator> */
249 if (unlikely(var3 == NULL)) {
250 PRINT_ERROR("Runtime error: %s", "Uninitialized attribute _sit");
251 PRINT_ERROR(" (%s:%d)\n", FILE_core__ropes, 1011);
252 fatal_exit(1);
253 }
254 var1 = var3;
255 RET_LABEL2:(void)0;
256 }
257 }
258 {
259 var4 = ((long(*)(val* self))((((long)var1&3)?class_info[((long)var1&3)]:var1->class)->vft[COLOR_core__abstract_collection__IndexedIterator__index]))(var1); /* index on <var1:IndexedIterator[Char]>*/
260 }
261 var = var4;
262 goto RET_LABEL;
263 RET_LABEL:;
264 return var;
265 }
266 /* method ropes#RopeBufferCharIterator#from for (self: RopeBufferCharIterator, RopeBuffer, Int) */
267 void core___core__RopeBufferCharIterator___from(val* self, val* p0, long p1) {
268 val* var_t /* var t: RopeBuffer */;
269 long var_pos /* var pos: Int */;
270 val* var /* : String */;
271 val* var3 /* : String */;
272 val* var4 /* : SequenceRead[Char] */;
273 val* var5 /* : IndexedIterator[nullable Object] */;
274 {
275 { /* Inline kernel#Object#init (self) on <self:RopeBufferCharIterator> */
276 RET_LABEL1:(void)0;
277 }
278 }
279 var_t = p0;
280 var_pos = p1;
281 {
282 core___core__RopeBuffer___persist_buffer(var_t); /* Direct call ropes#RopeBuffer#persist_buffer on <var_t:RopeBuffer>*/
283 }
284 {
285 { /* Inline ropes#RopeBuffer#str (var_t) on <var_t:RopeBuffer> */
286 var3 = var_t->attrs[COLOR_core__ropes__RopeBuffer___str].val; /* _str on <var_t:RopeBuffer> */
287 if (unlikely(var3 == NULL)) {
288 PRINT_ERROR("Runtime error: %s", "Uninitialized attribute _str");
289 PRINT_ERROR(" (%s:%d)\n", FILE_core__ropes, 310);
290 fatal_exit(1);
291 }
292 var = var3;
293 RET_LABEL2:(void)0;
294 }
295 }
296 {
297 var4 = ((val*(*)(val* self))(var->class->vft[COLOR_core__abstract_text__Text__chars]))(var); /* chars on <var:String>*/
298 }
299 {
300 var5 = ((val*(*)(val* self, long p0))((((long)var4&3)?class_info[((long)var4&3)]:var4->class)->vft[COLOR_core__abstract_collection__SequenceRead__iterator_from]))(var4, var_pos); /* iterator_from on <var4:SequenceRead[Char]>*/
301 }
302 {
303 { /* Inline ropes#RopeBufferCharIterator#sit= (self,var5) on <self:RopeBufferCharIterator> */
304 self->attrs[COLOR_core__ropes__RopeBufferCharIterator___sit].val = var5; /* _sit on <self:RopeBufferCharIterator> */
305 RET_LABEL6:(void)0;
306 }
307 }
308 RET_LABEL:;
309 }
310 /* method ropes#RopeBufferCharIterator#is_ok for (self: RopeBufferCharIterator): Bool */
311 short int core___core__RopeBufferCharIterator___core__abstract_collection__Iterator__is_ok(val* self) {
312 short int var /* : Bool */;
313 val* var1 /* : IndexedIterator[Char] */;
314 val* var3 /* : IndexedIterator[Char] */;
315 short int var4 /* : Bool */;
316 {
317 { /* Inline ropes#RopeBufferCharIterator#sit (self) on <self:RopeBufferCharIterator> */
318 var3 = self->attrs[COLOR_core__ropes__RopeBufferCharIterator___sit].val; /* _sit on <self:RopeBufferCharIterator> */
319 if (unlikely(var3 == NULL)) {
320 PRINT_ERROR("Runtime error: %s", "Uninitialized attribute _sit");
321 PRINT_ERROR(" (%s:%d)\n", FILE_core__ropes, 1011);
322 fatal_exit(1);
323 }
324 var1 = var3;
325 RET_LABEL2:(void)0;
326 }
327 }
328 {
329 var4 = ((short int(*)(val* self))((((long)var1&3)?class_info[((long)var1&3)]:var1->class)->vft[COLOR_core__abstract_collection__Iterator__is_ok]))(var1); /* is_ok on <var1:IndexedIterator[Char]>*/
330 }
331 var = var4;
332 goto RET_LABEL;
333 RET_LABEL:;
334 return var;
335 }
336 /* method ropes#RopeBufferCharIterator#item for (self: RopeBufferCharIterator): Char */
337 uint32_t core___core__RopeBufferCharIterator___core__abstract_collection__Iterator__item(val* self) {
338 uint32_t var /* : Char */;
339 short int var1 /* : Bool */;
340 val* var2 /* : IndexedIterator[Char] */;
341 val* var4 /* : IndexedIterator[Char] */;
342 val* var5 /* : nullable Object */;
343 uint32_t var6 /* : Char */;
344 {
345 var1 = core___core__RopeBufferCharIterator___core__abstract_collection__Iterator__is_ok(self);
346 }
347 if (unlikely(!var1)) {
348 PRINT_ERROR("Runtime error: %s", "Assert failed");
349 PRINT_ERROR(" (%s:%d)\n", FILE_core__ropes, 1025);
350 fatal_exit(1);
351 }
352 {
353 { /* Inline ropes#RopeBufferCharIterator#sit (self) on <self:RopeBufferCharIterator> */
354 var4 = self->attrs[COLOR_core__ropes__RopeBufferCharIterator___sit].val; /* _sit on <self:RopeBufferCharIterator> */
355 if (unlikely(var4 == NULL)) {
356 PRINT_ERROR("Runtime error: %s", "Uninitialized attribute _sit");
357 PRINT_ERROR(" (%s:%d)\n", FILE_core__ropes, 1011);
358 fatal_exit(1);
359 }
360 var2 = var4;
361 RET_LABEL3:(void)0;
362 }
363 }
364 {
365 var5 = ((val*(*)(val* self))((((long)var2&3)?class_info[((long)var2&3)]:var2->class)->vft[COLOR_core__abstract_collection__Iterator__item]))(var2); /* item on <var2:IndexedIterator[Char]>*/
366 }
367 var6 = (uint32_t)((long)(var5)>>2);
368 var = var6;
369 goto RET_LABEL;
370 RET_LABEL:;
371 return var;
372 }
373 /* method ropes#RopeBufferCharIterator#item for (self: Iterator[nullable Object]): nullable Object */
374 val* VIRTUAL_core___core__RopeBufferCharIterator___core__abstract_collection__Iterator__item(val* self) {
375 val* var /* : nullable Object */;
376 uint32_t var1 /* : Char */;
377 val* var2 /* : nullable Object */;
378 var1 = core___core__RopeBufferCharIterator___core__abstract_collection__Iterator__item(self);
379 var2 = (val*)((long)(var1)<<2|2);
380 var = var2;
381 RET_LABEL:;
382 return var;
383 }
384 /* method ropes#RopeBufferCharIterator#next for (self: RopeBufferCharIterator) */
385 void core___core__RopeBufferCharIterator___core__abstract_collection__Iterator__next(val* self) {
386 val* var /* : IndexedIterator[Char] */;
387 val* var2 /* : IndexedIterator[Char] */;
388 {
389 { /* Inline ropes#RopeBufferCharIterator#sit (self) on <self:RopeBufferCharIterator> */
390 var2 = self->attrs[COLOR_core__ropes__RopeBufferCharIterator___sit].val; /* _sit on <self:RopeBufferCharIterator> */
391 if (unlikely(var2 == NULL)) {
392 PRINT_ERROR("Runtime error: %s", "Uninitialized attribute _sit");
393 PRINT_ERROR(" (%s:%d)\n", FILE_core__ropes, 1011);
394 fatal_exit(1);
395 }
396 var = var2;
397 RET_LABEL1:(void)0;
398 }
399 }
400 {
401 ((void(*)(val* self))((((long)var&3)?class_info[((long)var&3)]:var->class)->vft[COLOR_core__abstract_collection__Iterator__next]))(var); /* next on <var:IndexedIterator[Char]>*/
402 }
403 RET_LABEL:;
404 }
405 /* method ropes#RopeBufferCharReverseIterator#sit for (self: RopeBufferCharReverseIterator): IndexedIterator[Char] */
406 val* core___core__RopeBufferCharReverseIterator___sit(val* self) {
407 val* var /* : IndexedIterator[Char] */;
408 val* var1 /* : IndexedIterator[Char] */;
409 var1 = self->attrs[COLOR_core__ropes__RopeBufferCharReverseIterator___sit].val; /* _sit on <self:RopeBufferCharReverseIterator> */
410 if (unlikely(var1 == NULL)) {
411 PRINT_ERROR("Runtime error: %s", "Uninitialized attribute _sit");
412 PRINT_ERROR(" (%s:%d)\n", FILE_core__ropes, 1036);
413 fatal_exit(1);
414 }
415 var = var1;
416 RET_LABEL:;
417 return var;
418 }
419 /* method ropes#RopeBufferCharReverseIterator#sit= for (self: RopeBufferCharReverseIterator, IndexedIterator[Char]) */
420 void core___core__RopeBufferCharReverseIterator___sit_61d(val* self, val* p0) {
421 self->attrs[COLOR_core__ropes__RopeBufferCharReverseIterator___sit].val = p0; /* _sit on <self:RopeBufferCharReverseIterator> */
422 RET_LABEL:;
423 }
424 /* method ropes#RopeBufferCharReverseIterator#index for (self: RopeBufferCharReverseIterator): Int */
425 long core___core__RopeBufferCharReverseIterator___core__abstract_collection__IndexedIterator__index(val* self) {
426 long var /* : Int */;
427 val* var1 /* : IndexedIterator[Char] */;
428 val* var3 /* : IndexedIterator[Char] */;
429 long var4 /* : Int */;
430 {
431 { /* Inline ropes#RopeBufferCharReverseIterator#sit (self) on <self:RopeBufferCharReverseIterator> */
432 var3 = self->attrs[COLOR_core__ropes__RopeBufferCharReverseIterator___sit].val; /* _sit on <self:RopeBufferCharReverseIterator> */
433 if (unlikely(var3 == NULL)) {
434 PRINT_ERROR("Runtime error: %s", "Uninitialized attribute _sit");
435 PRINT_ERROR(" (%s:%d)\n", FILE_core__ropes, 1036);
436 fatal_exit(1);
437 }
438 var1 = var3;
439 RET_LABEL2:(void)0;
440 }
441 }
442 {
443 var4 = ((long(*)(val* self))((((long)var1&3)?class_info[((long)var1&3)]:var1->class)->vft[COLOR_core__abstract_collection__IndexedIterator__index]))(var1); /* index on <var1:IndexedIterator[Char]>*/
444 }
445 var = var4;
446 goto RET_LABEL;
447 RET_LABEL:;
448 return var;
449 }
450 /* method ropes#RopeBufferCharReverseIterator#from for (self: RopeBufferCharReverseIterator, RopeBuffer, Int) */
451 void core___core__RopeBufferCharReverseIterator___from(val* self, val* p0, long p1) {
452 val* var_tgt /* var tgt: RopeBuffer */;
453 long var_pos /* var pos: Int */;
454 val* var /* : String */;
455 val* var3 /* : String */;
456 val* var4 /* : SequenceRead[Char] */;
457 val* var5 /* : IndexedIterator[nullable Object] */;
458 {
459 { /* Inline kernel#Object#init (self) on <self:RopeBufferCharReverseIterator> */
460 RET_LABEL1:(void)0;
461 }
462 }
463 var_tgt = p0;
464 var_pos = p1;
465 {
466 core___core__RopeBuffer___persist_buffer(var_tgt); /* Direct call ropes#RopeBuffer#persist_buffer on <var_tgt:RopeBuffer>*/
467 }
468 {
469 { /* Inline ropes#RopeBuffer#str (var_tgt) on <var_tgt:RopeBuffer> */
470 var3 = var_tgt->attrs[COLOR_core__ropes__RopeBuffer___str].val; /* _str on <var_tgt:RopeBuffer> */
471 if (unlikely(var3 == NULL)) {
472 PRINT_ERROR("Runtime error: %s", "Uninitialized attribute _str");
473 PRINT_ERROR(" (%s:%d)\n", FILE_core__ropes, 310);
474 fatal_exit(1);
475 }
476 var = var3;
477 RET_LABEL2:(void)0;
478 }
479 }
480 {
481 var4 = ((val*(*)(val* self))(var->class->vft[COLOR_core__abstract_text__Text__chars]))(var); /* chars on <var:String>*/
482 }
483 {
484 var5 = ((val*(*)(val* self, long p0))((((long)var4&3)?class_info[((long)var4&3)]:var4->class)->vft[COLOR_core__abstract_collection__SequenceRead__reverse_iterator_from]))(var4, var_pos); /* reverse_iterator_from on <var4:SequenceRead[Char]>*/
485 }
486 {
487 { /* Inline ropes#RopeBufferCharReverseIterator#sit= (self,var5) on <self:RopeBufferCharReverseIterator> */
488 self->attrs[COLOR_core__ropes__RopeBufferCharReverseIterator___sit].val = var5; /* _sit on <self:RopeBufferCharReverseIterator> */
489 RET_LABEL6:(void)0;
490 }
491 }
492 RET_LABEL:;
493 }
494 /* method ropes#RopeBufferCharReverseIterator#is_ok for (self: RopeBufferCharReverseIterator): Bool */
495 short int core___core__RopeBufferCharReverseIterator___core__abstract_collection__Iterator__is_ok(val* self) {
496 short int var /* : Bool */;
497 val* var1 /* : IndexedIterator[Char] */;
498 val* var3 /* : IndexedIterator[Char] */;
499 short int var4 /* : Bool */;
500 {
501 { /* Inline ropes#RopeBufferCharReverseIterator#sit (self) on <self:RopeBufferCharReverseIterator> */
502 var3 = self->attrs[COLOR_core__ropes__RopeBufferCharReverseIterator___sit].val; /* _sit on <self:RopeBufferCharReverseIterator> */
503 if (unlikely(var3 == NULL)) {
504 PRINT_ERROR("Runtime error: %s", "Uninitialized attribute _sit");
505 PRINT_ERROR(" (%s:%d)\n", FILE_core__ropes, 1036);
506 fatal_exit(1);
507 }
508 var1 = var3;
509 RET_LABEL2:(void)0;
510 }
511 }
512 {
513 var4 = ((short int(*)(val* self))((((long)var1&3)?class_info[((long)var1&3)]:var1->class)->vft[COLOR_core__abstract_collection__Iterator__is_ok]))(var1); /* is_ok on <var1:IndexedIterator[Char]>*/
514 }
515 var = var4;
516 goto RET_LABEL;
517 RET_LABEL:;
518 return var;
519 }
520 /* method ropes#RopeBufferCharReverseIterator#item for (self: RopeBufferCharReverseIterator): Char */
521 uint32_t core___core__RopeBufferCharReverseIterator___core__abstract_collection__Iterator__item(val* self) {
522 uint32_t var /* : Char */;
523 short int var1 /* : Bool */;
524 val* var2 /* : IndexedIterator[Char] */;
525 val* var4 /* : IndexedIterator[Char] */;
526 val* var5 /* : nullable Object */;
527 uint32_t var6 /* : Char */;
528 {
529 var1 = core___core__RopeBufferCharReverseIterator___core__abstract_collection__Iterator__is_ok(self);
530 }
531 if (unlikely(!var1)) {
532 PRINT_ERROR("Runtime error: %s", "Assert failed");
533 PRINT_ERROR(" (%s:%d)\n", FILE_core__ropes, 1050);
534 fatal_exit(1);
535 }
536 {
537 { /* Inline ropes#RopeBufferCharReverseIterator#sit (self) on <self:RopeBufferCharReverseIterator> */
538 var4 = self->attrs[COLOR_core__ropes__RopeBufferCharReverseIterator___sit].val; /* _sit on <self:RopeBufferCharReverseIterator> */
539 if (unlikely(var4 == NULL)) {
540 PRINT_ERROR("Runtime error: %s", "Uninitialized attribute _sit");
541 PRINT_ERROR(" (%s:%d)\n", FILE_core__ropes, 1036);
542 fatal_exit(1);
543 }
544 var2 = var4;
545 RET_LABEL3:(void)0;
546 }
547 }
548 {
549 var5 = ((val*(*)(val* self))((((long)var2&3)?class_info[((long)var2&3)]:var2->class)->vft[COLOR_core__abstract_collection__Iterator__item]))(var2); /* item on <var2:IndexedIterator[Char]>*/
550 }
551 var6 = (uint32_t)((long)(var5)>>2);
552 var = var6;
553 goto RET_LABEL;
554 RET_LABEL:;
555 return var;
556 }
557 /* method ropes#RopeBufferCharReverseIterator#item for (self: Iterator[nullable Object]): nullable Object */
558 val* VIRTUAL_core___core__RopeBufferCharReverseIterator___core__abstract_collection__Iterator__item(val* self) {
559 val* var /* : nullable Object */;
560 uint32_t var1 /* : Char */;
561 val* var2 /* : nullable Object */;
562 var1 = core___core__RopeBufferCharReverseIterator___core__abstract_collection__Iterator__item(self);
563 var2 = (val*)((long)(var1)<<2|2);
564 var = var2;
565 RET_LABEL:;
566 return var;
567 }
568 /* method ropes#RopeBufferCharReverseIterator#next for (self: RopeBufferCharReverseIterator) */
569 void core___core__RopeBufferCharReverseIterator___core__abstract_collection__Iterator__next(val* self) {
570 val* var /* : IndexedIterator[Char] */;
571 val* var2 /* : IndexedIterator[Char] */;
572 {
573 { /* Inline ropes#RopeBufferCharReverseIterator#sit (self) on <self:RopeBufferCharReverseIterator> */
574 var2 = self->attrs[COLOR_core__ropes__RopeBufferCharReverseIterator___sit].val; /* _sit on <self:RopeBufferCharReverseIterator> */
575 if (unlikely(var2 == NULL)) {
576 PRINT_ERROR("Runtime error: %s", "Uninitialized attribute _sit");
577 PRINT_ERROR(" (%s:%d)\n", FILE_core__ropes, 1036);
578 fatal_exit(1);
579 }
580 var = var2;
581 RET_LABEL1:(void)0;
582 }
583 }
584 {
585 ((void(*)(val* self))((((long)var&3)?class_info[((long)var&3)]:var->class)->vft[COLOR_core__abstract_collection__Iterator__next]))(var); /* next on <var:IndexedIterator[Char]>*/
586 }
587 RET_LABEL:;
588 }
589 /* method ropes#RopeBufferChars#[] for (self: RopeBufferChars, Int): Char */
590 uint32_t core___core__RopeBufferChars___core__abstract_collection__SequenceRead___91d_93d(val* self, long p0) {
591 uint32_t var /* : Char */;
592 long var_i /* var i: Int */;
593 val* var1 /* : Text */;
594 val* var3 /* : Text */;
595 uint32_t var4 /* : Char */;
596 var_i = p0;
597 {
598 { /* Inline abstract_text#StringCharView#target (self) on <self:RopeBufferChars> */
599 var3 = self->attrs[COLOR_core__abstract_text__StringCharView___target].val; /* _target on <self:RopeBufferChars> */
600 if (unlikely(var3 == NULL)) {
601 PRINT_ERROR("Runtime error: %s", "Uninitialized attribute _target");
602 PRINT_ERROR(" (%s:%d)\n", FILE_core__abstract_text, 1138);
603 fatal_exit(1);
604 }
605 var1 = var3;
606 RET_LABEL2:(void)0;
607 }
608 }
609 {
610 var4 = core___core__RopeBuffer___core__abstract_text__Text___91d_93d(var1, var_i);
611 }
612 var = var4;
613 goto RET_LABEL;
614 RET_LABEL:;
615 return var;
616 }
617 /* method ropes#RopeBufferChars#[] for (self: SequenceRead[nullable Object], Int): nullable Object */
618 val* VIRTUAL_core___core__RopeBufferChars___core__abstract_collection__SequenceRead___91d_93d(val* self, long p0) {
619 val* var /* : nullable Object */;
620 uint32_t var1 /* : Char */;
621 val* var2 /* : nullable Object */;
622 var1 = core___core__RopeBufferChars___core__abstract_collection__SequenceRead___91d_93d(self, p0);
623 var2 = (val*)((long)(var1)<<2|2);
624 var = var2;
625 RET_LABEL:;
626 return var;
627 }
628 /* method ropes#RopeBufferChars#[]= for (self: RopeBufferChars, Int, Char) */
629 void core___core__RopeBufferChars___core__abstract_collection__Sequence___91d_93d_61d(val* self, long p0, uint32_t p1) {
630 short int var /* : Bool */;
631 int cltype;
632 int idtype;
633 const char* var_class_name;
634 long var_i /* var i: Int */;
635 uint32_t var_c /* var c: Char */;
636 val* var1 /* : Text */;
637 val* var3 /* : Text */;
638 /* Covariant cast for argument 1 (c) <p1:Char> isa Char */
639 /* <p1:Char> isa Char */
640 var = 1; /* easy <p1:Char> isa Char*/
641 if (unlikely(!var)) {
642 var_class_name = type_core__Char.name;
643 PRINT_ERROR("Runtime error: Cast failed. Expected `%s`, got `%s`", "Char", var_class_name);
644 PRINT_ERROR(" (%s:%d)\n", FILE_core__ropes, 1065);
645 fatal_exit(1);
646 }
647 var_i = p0;
648 var_c = p1;
649 {
650 { /* Inline abstract_text#StringCharView#target (self) on <self:RopeBufferChars> */
651 var3 = self->attrs[COLOR_core__abstract_text__StringCharView___target].val; /* _target on <self:RopeBufferChars> */
652 if (unlikely(var3 == NULL)) {
653 PRINT_ERROR("Runtime error: %s", "Uninitialized attribute _target");
654 PRINT_ERROR(" (%s:%d)\n", FILE_core__abstract_text, 1138);
655 fatal_exit(1);
656 }
657 var1 = var3;
658 RET_LABEL2:(void)0;
659 }
660 }
661 {
662 core___core__RopeBuffer___core__abstract_text__Buffer___91d_93d_61d(var1, var_i, var_c); /* Direct call ropes#RopeBuffer#[]= on <var1:Text(RopeBuffer)>*/
663 }
664 RET_LABEL:;
665 }
666 /* method ropes#RopeBufferChars#[]= for (self: Sequence[nullable Object], Int, nullable Object) */
667 void VIRTUAL_core___core__RopeBufferChars___core__abstract_collection__Sequence___91d_93d_61d(val* self, long p0, val* p1) {
668 uint32_t var /* : Char */;
669 var = (uint32_t)((long)(p1)>>2);
670 core___core__RopeBufferChars___core__abstract_collection__Sequence___91d_93d_61d(self, p0, var); /* Direct call ropes#RopeBufferChars#[]= on <self:Sequence[nullable Object](RopeBufferChars)>*/
671 RET_LABEL:;
672 }
673 /* method ropes#RopeBufferChars#add for (self: RopeBufferChars, Char) */
674 void core___core__RopeBufferChars___core__abstract_collection__SimpleCollection__add(val* self, uint32_t p0) {
675 short int var /* : Bool */;
676 int cltype;
677 int idtype;
678 const char* var_class_name;
679 uint32_t var_c /* var c: Char */;
680 val* var1 /* : Text */;
681 val* var3 /* : Text */;
682 /* Covariant cast for argument 0 (c) <p0:Char> isa Char */
683 /* <p0:Char> isa Char */
684 var = 1; /* easy <p0:Char> isa Char*/
685 if (unlikely(!var)) {
686 var_class_name = type_core__Char.name;
687 PRINT_ERROR("Runtime error: Cast failed. Expected `%s`, got `%s`", "Char", var_class_name);
688 PRINT_ERROR(" (%s:%d)\n", FILE_core__ropes, 1067);
689 fatal_exit(1);
690 }
691 var_c = p0;
692 {
693 { /* Inline abstract_text#StringCharView#target (self) on <self:RopeBufferChars> */
694 var3 = self->attrs[COLOR_core__abstract_text__StringCharView___target].val; /* _target on <self:RopeBufferChars> */
695 if (unlikely(var3 == NULL)) {
696 PRINT_ERROR("Runtime error: %s", "Uninitialized attribute _target");
697 PRINT_ERROR(" (%s:%d)\n", FILE_core__abstract_text, 1138);
698 fatal_exit(1);
699 }
700 var1 = var3;
701 RET_LABEL2:(void)0;
702 }
703 }
704 {
705 core___core__RopeBuffer___core__abstract_text__Buffer__add(var1, var_c); /* Direct call ropes#RopeBuffer#add on <var1:Text(RopeBuffer)>*/
706 }
707 RET_LABEL:;
708 }
709 /* method ropes#RopeBufferChars#add for (self: SimpleCollection[nullable Object], nullable Object) */
710 void VIRTUAL_core___core__RopeBufferChars___core__abstract_collection__SimpleCollection__add(val* self, val* p0) {
711 uint32_t var /* : Char */;
712 var = (uint32_t)((long)(p0)>>2);
713 core___core__RopeBufferChars___core__abstract_collection__SimpleCollection__add(self, var); /* Direct call ropes#RopeBufferChars#add on <self:SimpleCollection[nullable Object](RopeBufferChars)>*/
714 RET_LABEL:;
715 }
716 /* method ropes#RopeBufferChars#push for (self: RopeBufferChars, Char) */
717 void core___core__RopeBufferChars___core__abstract_collection__Sequence__push(val* self, uint32_t p0) {
718 short int var /* : Bool */;
719 int cltype;
720 int idtype;
721 const char* var_class_name;
722 uint32_t var_c /* var c: Char */;
723 val* var1 /* : Text */;
724 val* var3 /* : Text */;
725 /* Covariant cast for argument 0 (c) <p0:Char> isa Char */
726 /* <p0:Char> isa Char */
727 var = 1; /* easy <p0:Char> isa Char*/
728 if (unlikely(!var)) {
729 var_class_name = type_core__Char.name;
730 PRINT_ERROR("Runtime error: Cast failed. Expected `%s`, got `%s`", "Char", var_class_name);
731 PRINT_ERROR(" (%s:%d)\n", FILE_core__ropes, 1069);
732 fatal_exit(1);
733 }
734 var_c = p0;
735 {
736 { /* Inline abstract_text#StringCharView#target (self) on <self:RopeBufferChars> */
737 var3 = self->attrs[COLOR_core__abstract_text__StringCharView___target].val; /* _target on <self:RopeBufferChars> */
738 if (unlikely(var3 == NULL)) {
739 PRINT_ERROR("Runtime error: %s", "Uninitialized attribute _target");
740 PRINT_ERROR(" (%s:%d)\n", FILE_core__abstract_text, 1138);
741 fatal_exit(1);
742 }
743 var1 = var3;
744 RET_LABEL2:(void)0;
745 }
746 }
747 {
748 core___core__RopeBuffer___core__abstract_text__Buffer__add(var1, var_c); /* Direct call ropes#RopeBuffer#add on <var1:Text(RopeBuffer)>*/
749 }
750 RET_LABEL:;
751 }
752 /* method ropes#RopeBufferChars#push for (self: Sequence[nullable Object], nullable Object) */
753 void VIRTUAL_core___core__RopeBufferChars___core__abstract_collection__Sequence__push(val* self, val* p0) {
754 uint32_t var /* : Char */;
755 var = (uint32_t)((long)(p0)>>2);
756 core___core__RopeBufferChars___core__abstract_collection__Sequence__push(self, var); /* Direct call ropes#RopeBufferChars#push on <self:Sequence[nullable Object](RopeBufferChars)>*/
757 RET_LABEL:;
758 }
759 /* method ropes#RopeBufferChars#iterator_from for (self: RopeBufferChars, Int): IndexedIterator[Char] */
760 val* core___core__RopeBufferChars___core__abstract_collection__SequenceRead__iterator_from(val* self, long p0) {
761 val* var /* : IndexedIterator[Char] */;
762 long var_i /* var i: Int */;
763 val* var1 /* : RopeBufferCharIterator */;
764 val* var2 /* : Text */;
765 val* var4 /* : Text */;
766 var_i = p0;
767 var1 = NEW_core__RopeBufferCharIterator(&type_core__RopeBufferCharIterator);
768 {
769 { /* Inline abstract_text#StringCharView#target (self) on <self:RopeBufferChars> */
770 var4 = self->attrs[COLOR_core__abstract_text__StringCharView___target].val; /* _target on <self:RopeBufferChars> */
771 if (unlikely(var4 == NULL)) {
772 PRINT_ERROR("Runtime error: %s", "Uninitialized attribute _target");
773 PRINT_ERROR(" (%s:%d)\n", FILE_core__abstract_text, 1138);
774 fatal_exit(1);
775 }
776 var2 = var4;
777 RET_LABEL3:(void)0;
778 }
779 }
780 {
781 core___core__RopeBufferCharIterator___from(var1, var2, var_i); /* Direct call ropes#RopeBufferCharIterator#from on <var1:RopeBufferCharIterator>*/
782 }
783 var = var1;
784 goto RET_LABEL;
785 RET_LABEL:;
786 return var;
787 }
788 /* method ropes#RopeBufferChars#reverse_iterator_from for (self: RopeBufferChars, Int): IndexedIterator[Char] */
789 val* core___core__RopeBufferChars___core__abstract_collection__SequenceRead__reverse_iterator_from(val* self, long p0) {
790 val* var /* : IndexedIterator[Char] */;
791 long var_i /* var i: Int */;
792 val* var1 /* : RopeBufferCharReverseIterator */;
793 val* var2 /* : Text */;
794 val* var4 /* : Text */;
795 var_i = p0;
796 var1 = NEW_core__RopeBufferCharReverseIterator(&type_core__RopeBufferCharReverseIterator);
797 {
798 { /* Inline abstract_text#StringCharView#target (self) on <self:RopeBufferChars> */
799 var4 = self->attrs[COLOR_core__abstract_text__StringCharView___target].val; /* _target on <self:RopeBufferChars> */
800 if (unlikely(var4 == NULL)) {
801 PRINT_ERROR("Runtime error: %s", "Uninitialized attribute _target");
802 PRINT_ERROR(" (%s:%d)\n", FILE_core__abstract_text, 1138);
803 fatal_exit(1);
804 }
805 var2 = var4;
806 RET_LABEL3:(void)0;
807 }
808 }
809 {
810 core___core__RopeBufferCharReverseIterator___from(var1, var2, var_i); /* Direct call ropes#RopeBufferCharReverseIterator#from on <var1:RopeBufferCharReverseIterator>*/
811 }
812 var = var1;
813 goto RET_LABEL;
814 RET_LABEL:;
815 return var;
816 }
817 /* method ropes#RopeBufferByteIterator#sit for (self: RopeBufferByteIterator): IndexedIterator[Byte] */
818 val* core___core__RopeBufferByteIterator___sit(val* self) {
819 val* var /* : IndexedIterator[Byte] */;
820 val* var1 /* : IndexedIterator[Byte] */;
821 var1 = self->attrs[COLOR_core__ropes__RopeBufferByteIterator___sit].val; /* _sit on <self:RopeBufferByteIterator> */
822 if (unlikely(var1 == NULL)) {
823 PRINT_ERROR("Runtime error: %s", "Uninitialized attribute _sit");
824 PRINT_ERROR(" (%s:%d)\n", FILE_core__ropes, 1080);
825 fatal_exit(1);
826 }
827 var = var1;
828 RET_LABEL:;
829 return var;
830 }
831 /* method ropes#RopeBufferByteIterator#sit= for (self: RopeBufferByteIterator, IndexedIterator[Byte]) */
832 void core___core__RopeBufferByteIterator___sit_61d(val* self, val* p0) {
833 self->attrs[COLOR_core__ropes__RopeBufferByteIterator___sit].val = p0; /* _sit on <self:RopeBufferByteIterator> */
834 RET_LABEL:;
835 }
836 /* method ropes#RopeBufferByteIterator#ns for (self: RopeBufferByteIterator): NativeString */
837 char* core___core__RopeBufferByteIterator___ns(val* self) {
838 char* var /* : NativeString */;
839 char* var1 /* : NativeString */;
840 var1 = self->attrs[COLOR_core__ropes__RopeBufferByteIterator___ns].str; /* _ns on <self:RopeBufferByteIterator> */
841 var = var1;
842 RET_LABEL:;
843 return var;
844 }
845 /* method ropes#RopeBufferByteIterator#ns= for (self: RopeBufferByteIterator, NativeString) */
846 void core___core__RopeBufferByteIterator___ns_61d(val* self, char* p0) {
847 self->attrs[COLOR_core__ropes__RopeBufferByteIterator___ns].str = p0; /* _ns on <self:RopeBufferByteIterator> */
848 RET_LABEL:;
849 }
850 /* method ropes#RopeBufferByteIterator#pns for (self: RopeBufferByteIterator): Int */
851 long core___core__RopeBufferByteIterator___pns(val* self) {
852 long var /* : Int */;
853 long var1 /* : Int */;
854 var1 = self->attrs[COLOR_core__ropes__RopeBufferByteIterator___pns].l; /* _pns on <self:RopeBufferByteIterator> */
855 var = var1;
856 RET_LABEL:;
857 return var;
858 }
859 /* method ropes#RopeBufferByteIterator#pns= for (self: RopeBufferByteIterator, Int) */
860 void core___core__RopeBufferByteIterator___pns_61d(val* self, long p0) {
861 self->attrs[COLOR_core__ropes__RopeBufferByteIterator___pns].l = p0; /* _pns on <self:RopeBufferByteIterator> */
862 RET_LABEL:;
863 }
864 /* method ropes#RopeBufferByteIterator#maxpos for (self: RopeBufferByteIterator): Int */
865 long core___core__RopeBufferByteIterator___maxpos(val* self) {
866 long var /* : Int */;
867 long var1 /* : Int */;
868 var1 = self->attrs[COLOR_core__ropes__RopeBufferByteIterator___maxpos].l; /* _maxpos on <self:RopeBufferByteIterator> */
869 var = var1;
870 RET_LABEL:;
871 return var;
872 }
873 /* method ropes#RopeBufferByteIterator#maxpos= for (self: RopeBufferByteIterator, Int) */
874 void core___core__RopeBufferByteIterator___maxpos_61d(val* self, long p0) {
875 self->attrs[COLOR_core__ropes__RopeBufferByteIterator___maxpos].l = p0; /* _maxpos on <self:RopeBufferByteIterator> */
876 RET_LABEL:;
877 }
878 /* method ropes#RopeBufferByteIterator#index for (self: RopeBufferByteIterator): Int */
879 long core___core__RopeBufferByteIterator___core__abstract_collection__IndexedIterator__index(val* self) {
880 long var /* : Int */;
881 long var1 /* : Int */;
882 var1 = self->attrs[COLOR_core__ropes__RopeBufferByteIterator___index].l; /* _index on <self:RopeBufferByteIterator> */
883 var = var1;
884 RET_LABEL:;
885 return var;
886 }
887 /* method ropes#RopeBufferByteIterator#index= for (self: RopeBufferByteIterator, Int) */
888 void core___core__RopeBufferByteIterator___index_61d(val* self, long p0) {
889 self->attrs[COLOR_core__ropes__RopeBufferByteIterator___index].l = p0; /* _index on <self:RopeBufferByteIterator> */
890 RET_LABEL:;
891 }
892 /* method ropes#RopeBufferByteIterator#from for (self: RopeBufferByteIterator, RopeBuffer, Int) */
893 void core___core__RopeBufferByteIterator___from(val* self, val* p0, long p1) {
894 val* var_t /* var t: RopeBuffer */;
895 long var_pos /* var pos: Int */;
896 char* var /* : NativeString */;
897 char* var3 /* : NativeString */;
898 long var5 /* : Int */;
899 val* var7 /* : String */;
900 val* var9 /* : String */;
901 val* var10 /* : SequenceRead[Byte] */;
902 val* var11 /* : IndexedIterator[nullable Object] */;
903 val* var13 /* : String */;
904 val* var15 /* : String */;
905 long var16 /* : Int */;
906 long var17 /* : Int */;
907 short int var19 /* : Bool */;
908 int cltype;
909 int idtype;
910 const char* var_class_name;
911 long var20 /* : Int */;
912 {
913 { /* Inline kernel#Object#init (self) on <self:RopeBufferByteIterator> */
914 RET_LABEL1:(void)0;
915 }
916 }
917 var_t = p0;
918 var_pos = p1;
919 {
920 { /* Inline ropes#RopeBuffer#ns (var_t) on <var_t:RopeBuffer> */
921 var3 = var_t->attrs[COLOR_core__ropes__RopeBuffer___ns].str; /* _ns on <var_t:RopeBuffer> */
922 var = var3;
923 RET_LABEL2:(void)0;
924 }
925 }
926 {
927 { /* Inline ropes#RopeBufferByteIterator#ns= (self,var) on <self:RopeBufferByteIterator> */
928 self->attrs[COLOR_core__ropes__RopeBufferByteIterator___ns].str = var; /* _ns on <self:RopeBufferByteIterator> */
929 RET_LABEL4:(void)0;
930 }
931 }
932 var5 = var_t->attrs[COLOR_core__ropes__RopeBuffer___bytelen].l; /* _bytelen on <var_t:RopeBuffer> */
933 {
934 { /* Inline ropes#RopeBufferByteIterator#maxpos= (self,var5) on <self:RopeBufferByteIterator> */
935 self->attrs[COLOR_core__ropes__RopeBufferByteIterator___maxpos].l = var5; /* _maxpos on <self:RopeBufferByteIterator> */
936 RET_LABEL6:(void)0;
937 }
938 }
939 {
940 { /* Inline ropes#RopeBuffer#str (var_t) on <var_t:RopeBuffer> */
941 var9 = var_t->attrs[COLOR_core__ropes__RopeBuffer___str].val; /* _str on <var_t:RopeBuffer> */
942 if (unlikely(var9 == NULL)) {
943 PRINT_ERROR("Runtime error: %s", "Uninitialized attribute _str");
944 PRINT_ERROR(" (%s:%d)\n", FILE_core__ropes, 310);
945 fatal_exit(1);
946 }
947 var7 = var9;
948 RET_LABEL8:(void)0;
949 }
950 }
951 {
952 var10 = ((val*(*)(val* self))(var7->class->vft[COLOR_core__abstract_text__Text__bytes]))(var7); /* bytes on <var7:String>*/
953 }
954 {
955 var11 = ((val*(*)(val* self, long p0))((((long)var10&3)?class_info[((long)var10&3)]:var10->class)->vft[COLOR_core__abstract_collection__SequenceRead__iterator_from]))(var10, var_pos); /* iterator_from on <var10:SequenceRead[Byte]>*/
956 }
957 {
958 { /* Inline ropes#RopeBufferByteIterator#sit= (self,var11) on <self:RopeBufferByteIterator> */
959 self->attrs[COLOR_core__ropes__RopeBufferByteIterator___sit].val = var11; /* _sit on <self:RopeBufferByteIterator> */
960 RET_LABEL12:(void)0;
961 }
962 }
963 {
964 { /* Inline ropes#RopeBuffer#str (var_t) on <var_t:RopeBuffer> */
965 var15 = var_t->attrs[COLOR_core__ropes__RopeBuffer___str].val; /* _str on <var_t:RopeBuffer> */
966 if (unlikely(var15 == NULL)) {
967 PRINT_ERROR("Runtime error: %s", "Uninitialized attribute _str");
968 PRINT_ERROR(" (%s:%d)\n", FILE_core__ropes, 310);
969 fatal_exit(1);
970 }
971 var13 = var15;
972 RET_LABEL14:(void)0;
973 }
974 }
975 {
976 var16 = ((long(*)(val* self))(var13->class->vft[COLOR_core__abstract_text__Text__length]))(var13); /* length on <var13:String>*/
977 }
978 {
979 { /* Inline kernel#Int#- (var_pos,var16) on <var_pos:Int> */
980 /* Covariant cast for argument 0 (i) <var16:Int> isa OTHER */
981 /* <var16:Int> isa OTHER */
982 var19 = 1; /* easy <var16:Int> isa OTHER*/
983 if (unlikely(!var19)) {
984 var_class_name = type_core__Int.name;
985 PRINT_ERROR("Runtime error: Cast failed. Expected `%s`, got `%s`", "OTHER", var_class_name);
986 PRINT_ERROR(" (%s:%d)\n", FILE_core__kernel, 734);
987 fatal_exit(1);
988 }
989 var20 = var_pos - var16;
990 var17 = var20;
991 goto RET_LABEL18;
992 RET_LABEL18:(void)0;
993 }
994 }
995 {
996 { /* Inline ropes#RopeBufferByteIterator#pns= (self,var17) on <self:RopeBufferByteIterator> */
997 self->attrs[COLOR_core__ropes__RopeBufferByteIterator___pns].l = var17; /* _pns on <self:RopeBufferByteIterator> */
998 RET_LABEL21:(void)0;
999 }
1000 }
1001 {
1002 { /* Inline ropes#RopeBufferByteIterator#index= (self,var_pos) on <self:RopeBufferByteIterator> */
1003 self->attrs[COLOR_core__ropes__RopeBufferByteIterator___index].l = var_pos; /* _index on <self:RopeBufferByteIterator> */
1004 RET_LABEL22:(void)0;
1005 }
1006 }
1007 RET_LABEL:;
1008 }
1009 /* method ropes#RopeBufferByteIterator#is_ok for (self: RopeBufferByteIterator): Bool */
1010 short int core___core__RopeBufferByteIterator___core__abstract_collection__Iterator__is_ok(val* self) {
1011 short int var /* : Bool */;
1012 long var1 /* : Int */;
1013 long var3 /* : Int */;
1014 long var4 /* : Int */;
1015 long var6 /* : Int */;
1016 short int var7 /* : Bool */;
1017 short int var9 /* : Bool */;
1018 int cltype;
1019 int idtype;
1020 const char* var_class_name;
1021 short int var10 /* : Bool */;
1022 {
1023 { /* Inline ropes#RopeBufferByteIterator#index (self) on <self:RopeBufferByteIterator> */
1024 var3 = self->attrs[COLOR_core__ropes__RopeBufferByteIterator___index].l; /* _index on <self:RopeBufferByteIterator> */
1025 var1 = var3;
1026 RET_LABEL2:(void)0;
1027 }
1028 }
1029 {
1030 { /* Inline ropes#RopeBufferByteIterator#maxpos (self) on <self:RopeBufferByteIterator> */
1031 var6 = self->attrs[COLOR_core__ropes__RopeBufferByteIterator___maxpos].l; /* _maxpos on <self:RopeBufferByteIterator> */
1032 var4 = var6;
1033 RET_LABEL5:(void)0;
1034 }
1035 }
1036 {
1037 { /* Inline kernel#Int#< (var1,var4) on <var1:Int> */
1038 /* Covariant cast for argument 0 (i) <var4:Int> isa OTHER */
1039 /* <var4:Int> isa OTHER */
1040 var9 = 1; /* easy <var4:Int> isa OTHER*/
1041 if (unlikely(!var9)) {
1042 var_class_name = type_core__Int.name;
1043 PRINT_ERROR("Runtime error: Cast failed. Expected `%s`, got `%s`", "OTHER", var_class_name);
1044 PRINT_ERROR(" (%s:%d)\n", FILE_core__kernel, 728);
1045 fatal_exit(1);
1046 }
1047 var10 = var1 < var4;
1048 var7 = var10;
1049 goto RET_LABEL8;
1050 RET_LABEL8:(void)0;
1051 }
1052 }
1053 var = var7;
1054 goto RET_LABEL;
1055 RET_LABEL:;
1056 return var;
1057 }
1058 /* method ropes#RopeBufferByteIterator#item for (self: RopeBufferByteIterator): Byte */
1059 unsigned char core___core__RopeBufferByteIterator___core__abstract_collection__Iterator__item(val* self) {
1060 unsigned char var /* : Byte */;
1061 val* var1 /* : IndexedIterator[Byte] */;
1062 val* var3 /* : IndexedIterator[Byte] */;
1063 short int var4 /* : Bool */;
1064 val* var5 /* : IndexedIterator[Byte] */;
1065 val* var7 /* : IndexedIterator[Byte] */;
1066 val* var8 /* : nullable Object */;
1067 unsigned char var9 /* : Byte */;
1068 char* var10 /* : NativeString */;
1069 char* var12 /* : NativeString */;
1070 long var13 /* : Int */;
1071 long var15 /* : Int */;
1072 unsigned char var16 /* : Byte */;
1073 unsigned char var18 /* : Byte */;
1074 {
1075 { /* Inline ropes#RopeBufferByteIterator#sit (self) on <self:RopeBufferByteIterator> */
1076 var3 = self->attrs[COLOR_core__ropes__RopeBufferByteIterator___sit].val; /* _sit on <self:RopeBufferByteIterator> */
1077 if (unlikely(var3 == NULL)) {
1078 PRINT_ERROR("Runtime error: %s", "Uninitialized attribute _sit");
1079 PRINT_ERROR(" (%s:%d)\n", FILE_core__ropes, 1080);
1080 fatal_exit(1);
1081 }
1082 var1 = var3;
1083 RET_LABEL2:(void)0;
1084 }
1085 }
1086 {
1087 var4 = ((short int(*)(val* self))((((long)var1&3)?class_info[((long)var1&3)]:var1->class)->vft[COLOR_core__abstract_collection__Iterator__is_ok]))(var1); /* is_ok on <var1:IndexedIterator[Byte]>*/
1088 }
1089 if (var4){
1090 {
1091 { /* Inline ropes#RopeBufferByteIterator#sit (self) on <self:RopeBufferByteIterator> */
1092 var7 = self->attrs[COLOR_core__ropes__RopeBufferByteIterator___sit].val; /* _sit on <self:RopeBufferByteIterator> */
1093 if (unlikely(var7 == NULL)) {
1094 PRINT_ERROR("Runtime error: %s", "Uninitialized attribute _sit");
1095 PRINT_ERROR(" (%s:%d)\n", FILE_core__ropes, 1080);
1096 fatal_exit(1);
1097 }
1098 var5 = var7;
1099 RET_LABEL6:(void)0;
1100 }
1101 }
1102 {
1103 var8 = ((val*(*)(val* self))((((long)var5&3)?class_info[((long)var5&3)]:var5->class)->vft[COLOR_core__abstract_collection__Iterator__item]))(var5); /* item on <var5:IndexedIterator[Byte]>*/
1104 }
1105 var9 = ((struct instance_core__Byte*)var8)->value; /* autounbox from nullable Object to Byte */;
1106 var = var9;
1107 goto RET_LABEL;
1108 } else {
1109 }
1110 {
1111 { /* Inline ropes#RopeBufferByteIterator#ns (self) on <self:RopeBufferByteIterator> */
1112 var12 = self->attrs[COLOR_core__ropes__RopeBufferByteIterator___ns].str; /* _ns on <self:RopeBufferByteIterator> */
1113 var10 = var12;
1114 RET_LABEL11:(void)0;
1115 }
1116 }
1117 {
1118 { /* Inline ropes#RopeBufferByteIterator#pns (self) on <self:RopeBufferByteIterator> */
1119 var15 = self->attrs[COLOR_core__ropes__RopeBufferByteIterator___pns].l; /* _pns on <self:RopeBufferByteIterator> */
1120 var13 = var15;
1121 RET_LABEL14:(void)0;
1122 }
1123 }
1124 {
1125 { /* Inline native#NativeString#[] (var10,var13) on <var10:NativeString> */
1126 var18 = (unsigned char)((int)var10[var13]);
1127 var16 = var18;
1128 goto RET_LABEL17;
1129 RET_LABEL17:(void)0;
1130 }
1131 }
1132 var = var16;
1133 goto RET_LABEL;
1134 RET_LABEL:;
1135 return var;
1136 }
1137 /* method ropes#RopeBufferByteIterator#item for (self: Iterator[nullable Object]): nullable Object */
1138 val* VIRTUAL_core___core__RopeBufferByteIterator___core__abstract_collection__Iterator__item(val* self) {
1139 val* var /* : nullable Object */;
1140 unsigned char var1 /* : Byte */;
1141 val* var2 /* : nullable Object */;
1142 var1 = core___core__RopeBufferByteIterator___core__abstract_collection__Iterator__item(self);
1143 var2 = BOX_core__Byte(var1); /* autobox from Byte to nullable Object */
1144 var = var2;
1145 RET_LABEL:;
1146 return var;
1147 }
1148 /* method ropes#RopeBufferByteIterator#next for (self: RopeBufferByteIterator) */
1149 void core___core__RopeBufferByteIterator___core__abstract_collection__Iterator__next(val* self) {
1150 val* var_ /* var : RopeBufferByteIterator */;
1151 long var /* : Int */;
1152 long var2 /* : Int */;
1153 long var3 /* : Int */;
1154 short int var5 /* : Bool */;
1155 int cltype;
1156 int idtype;
1157 const char* var_class_name;
1158 long var6 /* : Int */;
1159 val* var8 /* : IndexedIterator[Byte] */;
1160 val* var10 /* : IndexedIterator[Byte] */;
1161 short int var11 /* : Bool */;
1162 val* var12 /* : IndexedIterator[Byte] */;
1163 val* var14 /* : IndexedIterator[Byte] */;
1164 val* var_15 /* var : RopeBufferByteIterator */;
1165 long var16 /* : Int */;
1166 long var18 /* : Int */;
1167 long var19 /* : Int */;
1168 short int var21 /* : Bool */;
1169 int cltype22;
1170 int idtype23;
1171 const char* var_class_name24;
1172 long var25 /* : Int */;
1173 var_ = self;
1174 {
1175 { /* Inline ropes#RopeBufferByteIterator#index (var_) on <var_:RopeBufferByteIterator> */
1176 var2 = var_->attrs[COLOR_core__ropes__RopeBufferByteIterator___index].l; /* _index on <var_:RopeBufferByteIterator> */
1177 var = var2;
1178 RET_LABEL1:(void)0;
1179 }
1180 }
1181 {
1182 { /* Inline kernel#Int#+ (var,1l) on <var:Int> */
1183 /* Covariant cast for argument 0 (i) <1l:Int> isa OTHER */
1184 /* <1l:Int> isa OTHER */
1185 var5 = 1; /* easy <1l:Int> isa OTHER*/
1186 if (unlikely(!var5)) {
1187 var_class_name = type_core__Int.name;
1188 PRINT_ERROR("Runtime error: Cast failed. Expected `%s`, got `%s`", "OTHER", var_class_name);
1189 PRINT_ERROR(" (%s:%d)\n", FILE_core__kernel, 731);
1190 fatal_exit(1);
1191 }
1192 var6 = var + 1l;
1193 var3 = var6;
1194 goto RET_LABEL4;
1195 RET_LABEL4:(void)0;
1196 }
1197 }
1198 {
1199 { /* Inline ropes#RopeBufferByteIterator#index= (var_,var3) on <var_:RopeBufferByteIterator> */
1200 var_->attrs[COLOR_core__ropes__RopeBufferByteIterator___index].l = var3; /* _index on <var_:RopeBufferByteIterator> */
1201 RET_LABEL7:(void)0;
1202 }
1203 }
1204 {
1205 { /* Inline ropes#RopeBufferByteIterator#sit (self) on <self:RopeBufferByteIterator> */
1206 var10 = self->attrs[COLOR_core__ropes__RopeBufferByteIterator___sit].val; /* _sit on <self:RopeBufferByteIterator> */
1207 if (unlikely(var10 == NULL)) {
1208 PRINT_ERROR("Runtime error: %s", "Uninitialized attribute _sit");
1209 PRINT_ERROR(" (%s:%d)\n", FILE_core__ropes, 1080);
1210 fatal_exit(1);
1211 }
1212 var8 = var10;
1213 RET_LABEL9:(void)0;
1214 }
1215 }
1216 {
1217 var11 = ((short int(*)(val* self))((((long)var8&3)?class_info[((long)var8&3)]:var8->class)->vft[COLOR_core__abstract_collection__Iterator__is_ok]))(var8); /* is_ok on <var8:IndexedIterator[Byte]>*/
1218 }
1219 if (var11){
1220 {
1221 { /* Inline ropes#RopeBufferByteIterator#sit (self) on <self:RopeBufferByteIterator> */
1222 var14 = self->attrs[COLOR_core__ropes__RopeBufferByteIterator___sit].val; /* _sit on <self:RopeBufferByteIterator> */
1223 if (unlikely(var14 == NULL)) {
1224 PRINT_ERROR("Runtime error: %s", "Uninitialized attribute _sit");
1225 PRINT_ERROR(" (%s:%d)\n", FILE_core__ropes, 1080);
1226 fatal_exit(1);
1227 }
1228 var12 = var14;
1229 RET_LABEL13:(void)0;
1230 }
1231 }
1232 {
1233 ((void(*)(val* self))((((long)var12&3)?class_info[((long)var12&3)]:var12->class)->vft[COLOR_core__abstract_collection__Iterator__next]))(var12); /* next on <var12:IndexedIterator[Byte]>*/
1234 }
1235 } else {
1236 var_15 = self;
1237 {
1238 { /* Inline ropes#RopeBufferByteIterator#pns (var_15) on <var_15:RopeBufferByteIterator> */
1239 var18 = var_15->attrs[COLOR_core__ropes__RopeBufferByteIterator___pns].l; /* _pns on <var_15:RopeBufferByteIterator> */
1240 var16 = var18;
1241 RET_LABEL17:(void)0;
1242 }
1243 }
1244 {
1245 { /* Inline kernel#Int#+ (var16,1l) on <var16:Int> */
1246 /* Covariant cast for argument 0 (i) <1l:Int> isa OTHER */
1247 /* <1l:Int> isa OTHER */
1248 var21 = 1; /* easy <1l:Int> isa OTHER*/
1249 if (unlikely(!var21)) {
1250 var_class_name24 = type_core__Int.name;
1251 PRINT_ERROR("Runtime error: Cast failed. Expected `%s`, got `%s`", "OTHER", var_class_name24);
1252 PRINT_ERROR(" (%s:%d)\n", FILE_core__kernel, 731);
1253 fatal_exit(1);
1254 }
1255 var25 = var16 + 1l;
1256 var19 = var25;
1257 goto RET_LABEL20;
1258 RET_LABEL20:(void)0;
1259 }
1260 }
1261 {
1262 { /* Inline ropes#RopeBufferByteIterator#pns= (var_15,var19) on <var_15:RopeBufferByteIterator> */
1263 var_15->attrs[COLOR_core__ropes__RopeBufferByteIterator___pns].l = var19; /* _pns on <var_15:RopeBufferByteIterator> */
1264 RET_LABEL26:(void)0;
1265 }
1266 }
1267 }
1268 RET_LABEL:;
1269 }
1270 /* method ropes#RopeBufferByteReverseIterator#sit for (self: RopeBufferByteReverseIterator): IndexedIterator[Byte] */
1271 val* core___core__RopeBufferByteReverseIterator___sit(val* self) {
1272 val* var /* : IndexedIterator[Byte] */;
1273 val* var1 /* : IndexedIterator[Byte] */;
1274 var1 = self->attrs[COLOR_core__ropes__RopeBufferByteReverseIterator___sit].val; /* _sit on <self:RopeBufferByteReverseIterator> */
1275 if (unlikely(var1 == NULL)) {
1276 PRINT_ERROR("Runtime error: %s", "Uninitialized attribute _sit");
1277 PRINT_ERROR(" (%s:%d)\n", FILE_core__ropes, 1124);
1278 fatal_exit(1);
1279 }
1280 var = var1;
1281 RET_LABEL:;
1282 return var;
1283 }
1284 /* method ropes#RopeBufferByteReverseIterator#sit= for (self: RopeBufferByteReverseIterator, IndexedIterator[Byte]) */
1285 void core___core__RopeBufferByteReverseIterator___sit_61d(val* self, val* p0) {
1286 self->attrs[COLOR_core__ropes__RopeBufferByteReverseIterator___sit].val = p0; /* _sit on <self:RopeBufferByteReverseIterator> */
1287 RET_LABEL:;
1288 }
1289 /* method ropes#RopeBufferByteReverseIterator#ns for (self: RopeBufferByteReverseIterator): NativeString */
1290 char* core___core__RopeBufferByteReverseIterator___ns(val* self) {
1291 char* var /* : NativeString */;
1292 char* var1 /* : NativeString */;
1293 var1 = self->attrs[COLOR_core__ropes__RopeBufferByteReverseIterator___ns].str; /* _ns on <self:RopeBufferByteReverseIterator> */
1294 var = var1;
1295 RET_LABEL:;
1296 return var;
1297 }
1298 /* method ropes#RopeBufferByteReverseIterator#ns= for (self: RopeBufferByteReverseIterator, NativeString) */
1299 void core___core__RopeBufferByteReverseIterator___ns_61d(val* self, char* p0) {
1300 self->attrs[COLOR_core__ropes__RopeBufferByteReverseIterator___ns].str = p0; /* _ns on <self:RopeBufferByteReverseIterator> */
1301 RET_LABEL:;
1302 }
1303 /* method ropes#RopeBufferByteReverseIterator#pns for (self: RopeBufferByteReverseIterator): Int */
1304 long core___core__RopeBufferByteReverseIterator___pns(val* self) {
1305 long var /* : Int */;
1306 long var1 /* : Int */;
1307 var1 = self->attrs[COLOR_core__ropes__RopeBufferByteReverseIterator___pns].l; /* _pns on <self:RopeBufferByteReverseIterator> */
1308 var = var1;
1309 RET_LABEL:;
1310 return var;
1311 }
1312 /* method ropes#RopeBufferByteReverseIterator#pns= for (self: RopeBufferByteReverseIterator, Int) */
1313 void core___core__RopeBufferByteReverseIterator___pns_61d(val* self, long p0) {
1314 self->attrs[COLOR_core__ropes__RopeBufferByteReverseIterator___pns].l = p0; /* _pns on <self:RopeBufferByteReverseIterator> */
1315 RET_LABEL:;
1316 }
1317 /* method ropes#RopeBufferByteReverseIterator#index for (self: RopeBufferByteReverseIterator): Int */
1318 long core___core__RopeBufferByteReverseIterator___core__abstract_collection__IndexedIterator__index(val* self) {
1319 long var /* : Int */;
1320 long var1 /* : Int */;
1321 var1 = self->attrs[COLOR_core__ropes__RopeBufferByteReverseIterator___index].l; /* _index on <self:RopeBufferByteReverseIterator> */
1322 var = var1;
1323 RET_LABEL:;
1324 return var;
1325 }
1326 /* method ropes#RopeBufferByteReverseIterator#index= for (self: RopeBufferByteReverseIterator, Int) */
1327 void core___core__RopeBufferByteReverseIterator___index_61d(val* self, long p0) {
1328 self->attrs[COLOR_core__ropes__RopeBufferByteReverseIterator___index].l = p0; /* _index on <self:RopeBufferByteReverseIterator> */
1329 RET_LABEL:;
1330 }
1331 /* method ropes#RopeBufferByteReverseIterator#from for (self: RopeBufferByteReverseIterator, RopeBuffer, Int) */
1332 void core___core__RopeBufferByteReverseIterator___from(val* self, val* p0, long p1) {
1333 val* var_tgt /* var tgt: RopeBuffer */;
1334 long var_pos /* var pos: Int */;
1335 val* var /* : String */;
1336 val* var3 /* : String */;
1337 val* var4 /* : SequenceRead[Byte] */;
1338 long var5 /* : Int */;
1339 long var7 /* : Int */;
1340 long var8 /* : Int */;
1341 long var10 /* : Int */;
1342 long var11 /* : Int */;
1343 short int var13 /* : Bool */;
1344 int cltype;
1345 int idtype;
1346 const char* var_class_name;
1347 long var14 /* : Int */;
1348 long var15 /* : Int */;
1349 short int var17 /* : Bool */;
1350 int cltype18;
1351 int idtype19;
1352 const char* var_class_name20;
1353 long var21 /* : Int */;
1354 val* var22 /* : IndexedIterator[nullable Object] */;
1355 val* var24 /* : String */;
1356 val* var26 /* : String */;
1357 long var27 /* : Int */;
1358 long var28 /* : Int */;
1359 short int var30 /* : Bool */;
1360 int cltype31;
1361 int idtype32;
1362 const char* var_class_name33;
1363 long var34 /* : Int */;
1364 long var35 /* : Int */;
1365 long var37 /* : Int */;
1366 long var38 /* : Int */;
1367 short int var40 /* : Bool */;
1368 int cltype41;
1369 int idtype42;
1370 const char* var_class_name43;
1371 long var44 /* : Int */;
1372 char* var47 /* : NativeString */;
1373 char* var49 /* : NativeString */;
1374 {
1375 { /* Inline kernel#Object#init (self) on <self:RopeBufferByteReverseIterator> */
1376 RET_LABEL1:(void)0;
1377 }
1378 }
1379 var_tgt = p0;
1380 var_pos = p1;
1381 {
1382 { /* Inline ropes#RopeBuffer#str (var_tgt) on <var_tgt:RopeBuffer> */
1383 var3 = var_tgt->attrs[COLOR_core__ropes__RopeBuffer___str].val; /* _str on <var_tgt:RopeBuffer> */
1384 if (unlikely(var3 == NULL)) {
1385 PRINT_ERROR("Runtime error: %s", "Uninitialized attribute _str");
1386 PRINT_ERROR(" (%s:%d)\n", FILE_core__ropes, 310);
1387 fatal_exit(1);
1388 }
1389 var = var3;
1390 RET_LABEL2:(void)0;
1391 }
1392 }
1393 {
1394 var4 = ((val*(*)(val* self))(var->class->vft[COLOR_core__abstract_text__Text__bytes]))(var); /* bytes on <var:String>*/
1395 }
1396 {
1397 { /* Inline ropes#RopeBuffer#rpos (var_tgt) on <var_tgt:RopeBuffer> */
1398 var7 = var_tgt->attrs[COLOR_core__ropes__RopeBuffer___rpos].l; /* _rpos on <var_tgt:RopeBuffer> */
1399 var5 = var7;
1400 RET_LABEL6:(void)0;
1401 }
1402 }
1403 {
1404 { /* Inline ropes#RopeBuffer#dumped (var_tgt) on <var_tgt:RopeBuffer> */
1405 var10 = var_tgt->attrs[COLOR_core__ropes__RopeBuffer___dumped].l; /* _dumped on <var_tgt:RopeBuffer> */
1406 var8 = var10;
1407 RET_LABEL9:(void)0;
1408 }
1409 }
1410 {
1411 { /* Inline kernel#Int#- (var5,var8) on <var5:Int> */
1412 /* Covariant cast for argument 0 (i) <var8:Int> isa OTHER */
1413 /* <var8:Int> isa OTHER */
1414 var13 = 1; /* easy <var8:Int> isa OTHER*/
1415 if (unlikely(!var13)) {
1416 var_class_name = type_core__Int.name;
1417 PRINT_ERROR("Runtime error: Cast failed. Expected `%s`, got `%s`", "OTHER", var_class_name);
1418 PRINT_ERROR(" (%s:%d)\n", FILE_core__kernel, 734);
1419 fatal_exit(1);
1420 }
1421 var14 = var5 - var8;
1422 var11 = var14;
1423 goto RET_LABEL12;
1424 RET_LABEL12:(void)0;
1425 }
1426 }
1427 {
1428 { /* Inline kernel#Int#- (var_pos,var11) on <var_pos:Int> */
1429 /* Covariant cast for argument 0 (i) <var11:Int> isa OTHER */
1430 /* <var11:Int> isa OTHER */
1431 var17 = 1; /* easy <var11:Int> isa OTHER*/
1432 if (unlikely(!var17)) {
1433 var_class_name20 = type_core__Int.name;
1434 PRINT_ERROR("Runtime error: Cast failed. Expected `%s`, got `%s`", "OTHER", var_class_name20);
1435 PRINT_ERROR(" (%s:%d)\n", FILE_core__kernel, 734);
1436 fatal_exit(1);
1437 }
1438 var21 = var_pos - var11;
1439 var15 = var21;
1440 goto RET_LABEL16;
1441 RET_LABEL16:(void)0;
1442 }
1443 }
1444 {
1445 var22 = ((val*(*)(val* self, long p0))((((long)var4&3)?class_info[((long)var4&3)]:var4->class)->vft[COLOR_core__abstract_collection__SequenceRead__reverse_iterator_from]))(var4, var15); /* reverse_iterator_from on <var4:SequenceRead[Byte]>*/
1446 }
1447 {
1448 { /* Inline ropes#RopeBufferByteReverseIterator#sit= (self,var22) on <self:RopeBufferByteReverseIterator> */
1449 self->attrs[COLOR_core__ropes__RopeBufferByteReverseIterator___sit].val = var22; /* _sit on <self:RopeBufferByteReverseIterator> */
1450 RET_LABEL23:(void)0;
1451 }
1452 }
1453 {
1454 { /* Inline ropes#RopeBuffer#str (var_tgt) on <var_tgt:RopeBuffer> */
1455 var26 = var_tgt->attrs[COLOR_core__ropes__RopeBuffer___str].val; /* _str on <var_tgt:RopeBuffer> */
1456 if (unlikely(var26 == NULL)) {
1457 PRINT_ERROR("Runtime error: %s", "Uninitialized attribute _str");
1458 PRINT_ERROR(" (%s:%d)\n", FILE_core__ropes, 310);
1459 fatal_exit(1);
1460 }
1461 var24 = var26;
1462 RET_LABEL25:(void)0;
1463 }
1464 }
1465 {
1466 var27 = ((long(*)(val* self))(var24->class->vft[COLOR_core__abstract_text__Text__bytelen]))(var24); /* bytelen on <var24:String>*/
1467 }
1468 {
1469 { /* Inline kernel#Int#- (var_pos,var27) on <var_pos:Int> */
1470 /* Covariant cast for argument 0 (i) <var27:Int> isa OTHER */
1471 /* <var27:Int> isa OTHER */
1472 var30 = 1; /* easy <var27:Int> isa OTHER*/
1473 if (unlikely(!var30)) {
1474 var_class_name33 = type_core__Int.name;
1475 PRINT_ERROR("Runtime error: Cast failed. Expected `%s`, got `%s`", "OTHER", var_class_name33);
1476 PRINT_ERROR(" (%s:%d)\n", FILE_core__kernel, 734);
1477 fatal_exit(1);
1478 }
1479 var34 = var_pos - var27;
1480 var28 = var34;
1481 goto RET_LABEL29;
1482 RET_LABEL29:(void)0;
1483 }
1484 }
1485 {
1486 { /* Inline ropes#RopeBuffer#rpos (var_tgt) on <var_tgt:RopeBuffer> */
1487 var37 = var_tgt->attrs[COLOR_core__ropes__RopeBuffer___rpos].l; /* _rpos on <var_tgt:RopeBuffer> */
1488 var35 = var37;
1489 RET_LABEL36:(void)0;
1490 }
1491 }
1492 {
1493 { /* Inline kernel#Int#+ (var28,var35) on <var28:Int> */
1494 /* Covariant cast for argument 0 (i) <var35:Int> isa OTHER */
1495 /* <var35:Int> isa OTHER */
1496 var40 = 1; /* easy <var35:Int> isa OTHER*/
1497 if (unlikely(!var40)) {
1498 var_class_name43 = type_core__Int.name;
1499 PRINT_ERROR("Runtime error: Cast failed. Expected `%s`, got `%s`", "OTHER", var_class_name43);
1500 PRINT_ERROR(" (%s:%d)\n", FILE_core__kernel, 731);
1501 fatal_exit(1);
1502 }
1503 var44 = var28 + var35;
1504 var38 = var44;
1505 goto RET_LABEL39;
1506 RET_LABEL39:(void)0;
1507 }
1508 }
1509 {
1510 { /* Inline ropes#RopeBufferByteReverseIterator#pns= (self,var38) on <self:RopeBufferByteReverseIterator> */
1511 self->attrs[COLOR_core__ropes__RopeBufferByteReverseIterator___pns].l = var38; /* _pns on <self:RopeBufferByteReverseIterator> */
1512 RET_LABEL45:(void)0;
1513 }
1514 }
1515 {
1516 { /* Inline ropes#RopeBufferByteReverseIterator#index= (self,var_pos) on <self:RopeBufferByteReverseIterator> */
1517 self->attrs[COLOR_core__ropes__RopeBufferByteReverseIterator___index].l = var_pos; /* _index on <self:RopeBufferByteReverseIterator> */
1518 RET_LABEL46:(void)0;
1519 }
1520 }
1521 {
1522 { /* Inline ropes#RopeBuffer#ns (var_tgt) on <var_tgt:RopeBuffer> */
1523 var49 = var_tgt->attrs[COLOR_core__ropes__RopeBuffer___ns].str; /* _ns on <var_tgt:RopeBuffer> */
1524 var47 = var49;
1525 RET_LABEL48:(void)0;
1526 }
1527 }
1528 {
1529 { /* Inline ropes#RopeBufferByteReverseIterator#ns= (self,var47) on <self:RopeBufferByteReverseIterator> */
1530 self->attrs[COLOR_core__ropes__RopeBufferByteReverseIterator___ns].str = var47; /* _ns on <self:RopeBufferByteReverseIterator> */
1531 RET_LABEL50:(void)0;
1532 }
1533 }
1534 RET_LABEL:;
1535 }
1536 /* method ropes#RopeBufferByteReverseIterator#is_ok for (self: RopeBufferByteReverseIterator): Bool */
1537 short int core___core__RopeBufferByteReverseIterator___core__abstract_collection__Iterator__is_ok(val* self) {
1538 short int var /* : Bool */;
1539 long var1 /* : Int */;
1540 long var3 /* : Int */;
1541 short int var4 /* : Bool */;
1542 short int var6 /* : Bool */;
1543 int cltype;
1544 int idtype;
1545 const char* var_class_name;
1546 short int var7 /* : Bool */;
1547 {
1548 { /* Inline ropes#RopeBufferByteReverseIterator#index (self) on <self:RopeBufferByteReverseIterator> */
1549 var3 = self->attrs[COLOR_core__ropes__RopeBufferByteReverseIterator___index].l; /* _index on <self:RopeBufferByteReverseIterator> */
1550 var1 = var3;
1551 RET_LABEL2:(void)0;
1552 }
1553 }
1554 {
1555 { /* Inline kernel#Int#>= (var1,0l) on <var1:Int> */
1556 /* Covariant cast for argument 0 (i) <0l:Int> isa OTHER */
1557 /* <0l:Int> isa OTHER */
1558 var6 = 1; /* easy <0l:Int> isa OTHER*/
1559 if (unlikely(!var6)) {
1560 var_class_name = type_core__Int.name;
1561 PRINT_ERROR("Runtime error: Cast failed. Expected `%s`, got `%s`", "OTHER", var_class_name);
1562 PRINT_ERROR(" (%s:%d)\n", FILE_core__kernel, 729);
1563 fatal_exit(1);
1564 }
1565 var7 = var1 >= 0l;
1566 var4 = var7;
1567 goto RET_LABEL5;
1568 RET_LABEL5:(void)0;
1569 }
1570 }
1571 var = var4;
1572 goto RET_LABEL;
1573 RET_LABEL:;
1574 return var;
1575 }
1576 /* method ropes#RopeBufferByteReverseIterator#item for (self: RopeBufferByteReverseIterator): Byte */
1577 unsigned char core___core__RopeBufferByteReverseIterator___core__abstract_collection__Iterator__item(val* self) {
1578 unsigned char var /* : Byte */;
1579 long var1 /* : Int */;
1580 long var3 /* : Int */;
1581 short int var4 /* : Bool */;
1582 short int var6 /* : Bool */;
1583 int cltype;
1584 int idtype;
1585 const char* var_class_name;
1586 short int var7 /* : Bool */;
1587 char* var8 /* : NativeString */;
1588 char* var10 /* : NativeString */;
1589 long var11 /* : Int */;
1590 long var13 /* : Int */;
1591 unsigned char var14 /* : Byte */;
1592 unsigned char var16 /* : Byte */;
1593 val* var17 /* : IndexedIterator[Byte] */;
1594 val* var19 /* : IndexedIterator[Byte] */;
1595 val* var20 /* : nullable Object */;
1596 unsigned char var21 /* : Byte */;
1597 {
1598 { /* Inline ropes#RopeBufferByteReverseIterator#pns (self) on <self:RopeBufferByteReverseIterator> */
1599 var3 = self->attrs[COLOR_core__ropes__RopeBufferByteReverseIterator___pns].l; /* _pns on <self:RopeBufferByteReverseIterator> */
1600 var1 = var3;
1601 RET_LABEL2:(void)0;
1602 }
1603 }
1604 {
1605 { /* Inline kernel#Int#>= (var1,0l) on <var1:Int> */
1606 /* Covariant cast for argument 0 (i) <0l:Int> isa OTHER */
1607 /* <0l:Int> isa OTHER */
1608 var6 = 1; /* easy <0l:Int> isa OTHER*/
1609 if (unlikely(!var6)) {
1610 var_class_name = type_core__Int.name;
1611 PRINT_ERROR("Runtime error: Cast failed. Expected `%s`, got `%s`", "OTHER", var_class_name);
1612 PRINT_ERROR(" (%s:%d)\n", FILE_core__kernel, 729);
1613 fatal_exit(1);
1614 }
1615 var7 = var1 >= 0l;
1616 var4 = var7;
1617 goto RET_LABEL5;
1618 RET_LABEL5:(void)0;
1619 }
1620 }
1621 if (var4){
1622 {
1623 { /* Inline ropes#RopeBufferByteReverseIterator#ns (self) on <self:RopeBufferByteReverseIterator> */
1624 var10 = self->attrs[COLOR_core__ropes__RopeBufferByteReverseIterator___ns].str; /* _ns on <self:RopeBufferByteReverseIterator> */
1625 var8 = var10;
1626 RET_LABEL9:(void)0;
1627 }
1628 }
1629 {
1630 { /* Inline ropes#RopeBufferByteReverseIterator#pns (self) on <self:RopeBufferByteReverseIterator> */
1631 var13 = self->attrs[COLOR_core__ropes__RopeBufferByteReverseIterator___pns].l; /* _pns on <self:RopeBufferByteReverseIterator> */
1632 var11 = var13;
1633 RET_LABEL12:(void)0;
1634 }
1635 }
1636 {
1637 { /* Inline native#NativeString#[] (var8,var11) on <var8:NativeString> */
1638 var16 = (unsigned char)((int)var8[var11]);
1639 var14 = var16;
1640 goto RET_LABEL15;
1641 RET_LABEL15:(void)0;
1642 }
1643 }
1644 var = var14;
1645 goto RET_LABEL;
1646 } else {
1647 }
1648 {
1649 { /* Inline ropes#RopeBufferByteReverseIterator#sit (self) on <self:RopeBufferByteReverseIterator> */
1650 var19 = self->attrs[COLOR_core__ropes__RopeBufferByteReverseIterator___sit].val; /* _sit on <self:RopeBufferByteReverseIterator> */
1651 if (unlikely(var19 == NULL)) {
1652 PRINT_ERROR("Runtime error: %s", "Uninitialized attribute _sit");
1653 PRINT_ERROR(" (%s:%d)\n", FILE_core__ropes, 1124);
1654 fatal_exit(1);
1655 }
1656 var17 = var19;
1657 RET_LABEL18:(void)0;
1658 }
1659 }
1660 {
1661 var20 = ((val*(*)(val* self))((((long)var17&3)?class_info[((long)var17&3)]:var17->class)->vft[COLOR_core__abstract_collection__Iterator__item]))(var17); /* item on <var17:IndexedIterator[Byte]>*/
1662 }
1663 var21 = ((struct instance_core__Byte*)var20)->value; /* autounbox from nullable Object to Byte */;
1664 var = var21;
1665 goto RET_LABEL;
1666 RET_LABEL:;
1667 return var;
1668 }
1669 /* method ropes#RopeBufferByteReverseIterator#item for (self: Iterator[nullable Object]): nullable Object */
1670 val* VIRTUAL_core___core__RopeBufferByteReverseIterator___core__abstract_collection__Iterator__item(val* self) {
1671 val* var /* : nullable Object */;
1672 unsigned char var1 /* : Byte */;
1673 val* var2 /* : nullable Object */;
1674 var1 = core___core__RopeBufferByteReverseIterator___core__abstract_collection__Iterator__item(self);
1675 var2 = BOX_core__Byte(var1); /* autobox from Byte to nullable Object */
1676 var = var2;
1677 RET_LABEL:;
1678 return var;
1679 }
1680 /* method ropes#RopeBufferByteReverseIterator#next for (self: RopeBufferByteReverseIterator) */
1681 void core___core__RopeBufferByteReverseIterator___core__abstract_collection__Iterator__next(val* self) {
1682 val* var_ /* var : RopeBufferByteReverseIterator */;
1683 long var /* : Int */;
1684 long var2 /* : Int */;
1685 long var3 /* : Int */;
1686 short int var5 /* : Bool */;
1687 int cltype;
1688 int idtype;
1689 const char* var_class_name;
1690 long var6 /* : Int */;
1691 long var8 /* : Int */;
1692 long var10 /* : Int */;
1693 short int var11 /* : Bool */;
1694 short int var13 /* : Bool */;
1695 int cltype14;
1696 int idtype15;
1697 const char* var_class_name16;
1698 short int var17 /* : Bool */;
1699 val* var_18 /* var : RopeBufferByteReverseIterator */;
1700 long var19 /* : Int */;
1701 long var21 /* : Int */;
1702 long var22 /* : Int */;
1703 short int var24 /* : Bool */;
1704 int cltype25;
1705 int idtype26;
1706 const char* var_class_name27;
1707 long var28 /* : Int */;
1708 val* var30 /* : IndexedIterator[Byte] */;
1709 val* var32 /* : IndexedIterator[Byte] */;
1710 var_ = self;
1711 {
1712 { /* Inline ropes#RopeBufferByteReverseIterator#index (var_) on <var_:RopeBufferByteReverseIterator> */
1713 var2 = var_->attrs[COLOR_core__ropes__RopeBufferByteReverseIterator___index].l; /* _index on <var_:RopeBufferByteReverseIterator> */
1714 var = var2;
1715 RET_LABEL1:(void)0;
1716 }
1717 }
1718 {
1719 { /* Inline kernel#Int#- (var,1l) on <var:Int> */
1720 /* Covariant cast for argument 0 (i) <1l:Int> isa OTHER */
1721 /* <1l:Int> isa OTHER */
1722 var5 = 1; /* easy <1l:Int> isa OTHER*/
1723 if (unlikely(!var5)) {
1724 var_class_name = type_core__Int.name;
1725 PRINT_ERROR("Runtime error: Cast failed. Expected `%s`, got `%s`", "OTHER", var_class_name);
1726 PRINT_ERROR(" (%s:%d)\n", FILE_core__kernel, 734);
1727 fatal_exit(1);
1728 }
1729 var6 = var - 1l;
1730 var3 = var6;
1731 goto RET_LABEL4;
1732 RET_LABEL4:(void)0;
1733 }
1734 }
1735 {
1736 { /* Inline ropes#RopeBufferByteReverseIterator#index= (var_,var3) on <var_:RopeBufferByteReverseIterator> */
1737 var_->attrs[COLOR_core__ropes__RopeBufferByteReverseIterator___index].l = var3; /* _index on <var_:RopeBufferByteReverseIterator> */
1738 RET_LABEL7:(void)0;
1739 }
1740 }
1741 {
1742 { /* Inline ropes#RopeBufferByteReverseIterator#pns (self) on <self:RopeBufferByteReverseIterator> */
1743 var10 = self->attrs[COLOR_core__ropes__RopeBufferByteReverseIterator___pns].l; /* _pns on <self:RopeBufferByteReverseIterator> */
1744 var8 = var10;
1745 RET_LABEL9:(void)0;
1746 }
1747 }
1748 {
1749 { /* Inline kernel#Int#>= (var8,0l) on <var8:Int> */
1750 /* Covariant cast for argument 0 (i) <0l:Int> isa OTHER */
1751 /* <0l:Int> isa OTHER */
1752 var13 = 1; /* easy <0l:Int> isa OTHER*/
1753 if (unlikely(!var13)) {
1754 var_class_name16 = type_core__Int.name;
1755 PRINT_ERROR("Runtime error: Cast failed. Expected `%s`, got `%s`", "OTHER", var_class_name16);
1756 PRINT_ERROR(" (%s:%d)\n", FILE_core__kernel, 729);
1757 fatal_exit(1);
1758 }
1759 var17 = var8 >= 0l;
1760 var11 = var17;
1761 goto RET_LABEL12;
1762 RET_LABEL12:(void)0;
1763 }
1764 }
1765 if (var11){
1766 var_18 = self;
1767 {
1768 { /* Inline ropes#RopeBufferByteReverseIterator#pns (var_18) on <var_18:RopeBufferByteReverseIterator> */
1769 var21 = var_18->attrs[COLOR_core__ropes__RopeBufferByteReverseIterator___pns].l; /* _pns on <var_18:RopeBufferByteReverseIterator> */
1770 var19 = var21;
1771 RET_LABEL20:(void)0;
1772 }
1773 }
1774 {
1775 { /* Inline kernel#Int#- (var19,1l) on <var19:Int> */
1776 /* Covariant cast for argument 0 (i) <1l:Int> isa OTHER */
1777 /* <1l:Int> isa OTHER */
1778 var24 = 1; /* easy <1l:Int> isa OTHER*/
1779 if (unlikely(!var24)) {
1780 var_class_name27 = type_core__Int.name;
1781 PRINT_ERROR("Runtime error: Cast failed. Expected `%s`, got `%s`", "OTHER", var_class_name27);
1782 PRINT_ERROR(" (%s:%d)\n", FILE_core__kernel, 734);
1783 fatal_exit(1);
1784 }
1785 var28 = var19 - 1l;
1786 var22 = var28;
1787 goto RET_LABEL23;
1788 RET_LABEL23:(void)0;
1789 }
1790 }
1791 {
1792 { /* Inline ropes#RopeBufferByteReverseIterator#pns= (var_18,var22) on <var_18:RopeBufferByteReverseIterator> */
1793 var_18->attrs[COLOR_core__ropes__RopeBufferByteReverseIterator___pns].l = var22; /* _pns on <var_18:RopeBufferByteReverseIterator> */
1794 RET_LABEL29:(void)0;
1795 }
1796 }
1797 } else {
1798 {
1799 { /* Inline ropes#RopeBufferByteReverseIterator#sit (self) on <self:RopeBufferByteReverseIterator> */
1800 var32 = self->attrs[COLOR_core__ropes__RopeBufferByteReverseIterator___sit].val; /* _sit on <self:RopeBufferByteReverseIterator> */
1801 if (unlikely(var32 == NULL)) {
1802 PRINT_ERROR("Runtime error: %s", "Uninitialized attribute _sit");
1803 PRINT_ERROR(" (%s:%d)\n", FILE_core__ropes, 1124);
1804 fatal_exit(1);
1805 }
1806 var30 = var32;
1807 RET_LABEL31:(void)0;
1808 }
1809 }
1810 {
1811 ((void(*)(val* self))((((long)var30&3)?class_info[((long)var30&3)]:var30->class)->vft[COLOR_core__abstract_collection__Iterator__next]))(var30); /* next on <var30:IndexedIterator[Byte]>*/
1812 }
1813 }
1814 RET_LABEL:;
1815 }
1816 /* method ropes#RopeBufferBytes#[] for (self: RopeBufferBytes, Int): Byte */
1817 unsigned char core___core__RopeBufferBytes___core__abstract_collection__SequenceRead___91d_93d(val* self, long p0) {
1818 unsigned char var /* : Byte */;
1819 long var_i /* var i: Int */;
1820 val* var1 /* : Text */;
1821 val* var3 /* : Text */;
1822 val* var4 /* : String */;
1823 val* var6 /* : String */;
1824 long var7 /* : Int */;
1825 short int var8 /* : Bool */;
1826 short int var10 /* : Bool */;
1827 int cltype;
1828 int idtype;
1829 const char* var_class_name;
1830 short int var11 /* : Bool */;
1831 val* var12 /* : Text */;
1832 val* var14 /* : Text */;
1833 val* var15 /* : String */;
1834 val* var17 /* : String */;
1835 val* var18 /* : SequenceRead[Byte] */;
1836 val* var19 /* : nullable Object */;
1837 unsigned char var20 /* : Byte */;
1838 val* var21 /* : Text */;
1839 val* var23 /* : Text */;
1840 char* var24 /* : NativeString */;
1841 char* var26 /* : NativeString */;
1842 val* var27 /* : Text */;
1843 val* var29 /* : Text */;
1844 val* var30 /* : String */;
1845 val* var32 /* : String */;
1846 long var33 /* : Int */;
1847 long var34 /* : Int */;
1848 short int var36 /* : Bool */;
1849 int cltype37;
1850 int idtype38;
1851 const char* var_class_name39;
1852 long var40 /* : Int */;
1853 unsigned char var41 /* : Byte */;
1854 unsigned char var43 /* : Byte */;
1855 var_i = p0;
1856 {
1857 { /* Inline abstract_text#StringByteView#target (self) on <self:RopeBufferBytes> */
1858 var3 = self->attrs[COLOR_core__abstract_text__StringByteView___target].val; /* _target on <self:RopeBufferBytes> */
1859 if (unlikely(var3 == NULL)) {
1860 PRINT_ERROR("Runtime error: %s", "Uninitialized attribute _target");
1861 PRINT_ERROR(" (%s:%d)\n", FILE_core__abstract_text, 1156);
1862 fatal_exit(1);
1863 }
1864 var1 = var3;
1865 RET_LABEL2:(void)0;
1866 }
1867 }
1868 {
1869 { /* Inline ropes#RopeBuffer#str (var1) on <var1:Text(RopeBuffer)> */
1870 var6 = var1->attrs[COLOR_core__ropes__RopeBuffer___str].val; /* _str on <var1:Text(RopeBuffer)> */
1871 if (unlikely(var6 == NULL)) {
1872 PRINT_ERROR("Runtime error: %s", "Uninitialized attribute _str");
1873 PRINT_ERROR(" (%s:%d)\n", FILE_core__ropes, 310);
1874 fatal_exit(1);
1875 }
1876 var4 = var6;
1877 RET_LABEL5:(void)0;
1878 }
1879 }
1880 {
1881 var7 = ((long(*)(val* self))(var4->class->vft[COLOR_core__abstract_text__Text__bytelen]))(var4); /* bytelen on <var4:String>*/
1882 }
1883 {
1884 { /* Inline kernel#Int#< (var_i,var7) on <var_i:Int> */
1885 /* Covariant cast for argument 0 (i) <var7:Int> isa OTHER */
1886 /* <var7:Int> isa OTHER */
1887 var10 = 1; /* easy <var7:Int> isa OTHER*/
1888 if (unlikely(!var10)) {
1889 var_class_name = type_core__Int.name;
1890 PRINT_ERROR("Runtime error: Cast failed. Expected `%s`, got `%s`", "OTHER", var_class_name);
1891 PRINT_ERROR(" (%s:%d)\n", FILE_core__kernel, 728);
1892 fatal_exit(1);
1893 }
1894 var11 = var_i < var7;
1895 var8 = var11;
1896 goto RET_LABEL9;
1897 RET_LABEL9:(void)0;
1898 }
1899 }
1900 if (var8){
1901 {
1902 { /* Inline abstract_text#StringByteView#target (self) on <self:RopeBufferBytes> */
1903 var14 = self->attrs[COLOR_core__abstract_text__StringByteView___target].val; /* _target on <self:RopeBufferBytes> */
1904 if (unlikely(var14 == NULL)) {
1905 PRINT_ERROR("Runtime error: %s", "Uninitialized attribute _target");
1906 PRINT_ERROR(" (%s:%d)\n", FILE_core__abstract_text, 1156);
1907 fatal_exit(1);
1908 }
1909 var12 = var14;
1910 RET_LABEL13:(void)0;
1911 }
1912 }
1913 {
1914 { /* Inline ropes#RopeBuffer#str (var12) on <var12:Text(RopeBuffer)> */
1915 var17 = var12->attrs[COLOR_core__ropes__RopeBuffer___str].val; /* _str on <var12:Text(RopeBuffer)> */
1916 if (unlikely(var17 == NULL)) {
1917 PRINT_ERROR("Runtime error: %s", "Uninitialized attribute _str");
1918 PRINT_ERROR(" (%s:%d)\n", FILE_core__ropes, 310);
1919 fatal_exit(1);
1920 }
1921 var15 = var17;
1922 RET_LABEL16:(void)0;
1923 }
1924 }
1925 {
1926 var18 = ((val*(*)(val* self))(var15->class->vft[COLOR_core__abstract_text__Text__bytes]))(var15); /* bytes on <var15:String>*/
1927 }
1928 {
1929 var19 = ((val*(*)(val* self, long p0))((((long)var18&3)?class_info[((long)var18&3)]:var18->class)->vft[COLOR_core__abstract_collection__SequenceRead___91d_93d]))(var18, var_i); /* [] on <var18:SequenceRead[Byte]>*/
1930 }
1931 var20 = ((struct instance_core__Byte*)var19)->value; /* autounbox from nullable Object to Byte */;
1932 var = var20;
1933 goto RET_LABEL;
1934 } else {
1935 {
1936 { /* Inline abstract_text#StringByteView#target (self) on <self:RopeBufferBytes> */
1937 var23 = self->attrs[COLOR_core__abstract_text__StringByteView___target].val; /* _target on <self:RopeBufferBytes> */
1938 if (unlikely(var23 == NULL)) {
1939 PRINT_ERROR("Runtime error: %s", "Uninitialized attribute _target");
1940 PRINT_ERROR(" (%s:%d)\n", FILE_core__abstract_text, 1156);
1941 fatal_exit(1);
1942 }
1943 var21 = var23;
1944 RET_LABEL22:(void)0;
1945 }
1946 }
1947 {
1948 { /* Inline ropes#RopeBuffer#ns (var21) on <var21:Text(RopeBuffer)> */
1949 var26 = var21->attrs[COLOR_core__ropes__RopeBuffer___ns].str; /* _ns on <var21:Text(RopeBuffer)> */
1950 var24 = var26;
1951 RET_LABEL25:(void)0;
1952 }
1953 }
1954 {
1955 { /* Inline abstract_text#StringByteView#target (self) on <self:RopeBufferBytes> */
1956 var29 = self->attrs[COLOR_core__abstract_text__StringByteView___target].val; /* _target on <self:RopeBufferBytes> */
1957 if (unlikely(var29 == NULL)) {
1958 PRINT_ERROR("Runtime error: %s", "Uninitialized attribute _target");
1959 PRINT_ERROR(" (%s:%d)\n", FILE_core__abstract_text, 1156);
1960 fatal_exit(1);
1961 }
1962 var27 = var29;
1963 RET_LABEL28:(void)0;
1964 }
1965 }
1966 {
1967 { /* Inline ropes#RopeBuffer#str (var27) on <var27:Text(RopeBuffer)> */
1968 var32 = var27->attrs[COLOR_core__ropes__RopeBuffer___str].val; /* _str on <var27:Text(RopeBuffer)> */
1969 if (unlikely(var32 == NULL)) {
1970 PRINT_ERROR("Runtime error: %s", "Uninitialized attribute _str");
1971 PRINT_ERROR(" (%s:%d)\n", FILE_core__ropes, 310);
1972 fatal_exit(1);
1973 }
1974 var30 = var32;
1975 RET_LABEL31:(void)0;
1976 }
1977 }
1978 {
1979 var33 = ((long(*)(val* self))(var30->class->vft[COLOR_core__abstract_text__Text__bytelen]))(var30); /* bytelen on <var30:String>*/
1980 }
1981 {
1982 { /* Inline kernel#Int#- (var_i,var33) on <var_i:Int> */
1983 /* Covariant cast for argument 0 (i) <var33:Int> isa OTHER */
1984 /* <var33:Int> isa OTHER */
1985 var36 = 1; /* easy <var33:Int> isa OTHER*/
1986 if (unlikely(!var36)) {
1987 var_class_name39 = type_core__Int.name;
1988 PRINT_ERROR("Runtime error: Cast failed. Expected `%s`, got `%s`", "OTHER", var_class_name39);
1989 PRINT_ERROR(" (%s:%d)\n", FILE_core__kernel, 734);
1990 fatal_exit(1);
1991 }
1992 var40 = var_i - var33;
1993 var34 = var40;
1994 goto RET_LABEL35;
1995 RET_LABEL35:(void)0;
1996 }
1997 }
1998 {
1999 { /* Inline native#NativeString#[] (var24,var34) on <var24:NativeString> */
2000 var43 = (unsigned char)((int)var24[var34]);
2001 var41 = var43;
2002 goto RET_LABEL42;
2003 RET_LABEL42:(void)0;
2004 }
2005 }
2006 var = var41;
2007 goto RET_LABEL;
2008 }
2009 RET_LABEL:;
2010 return var;
2011 }
2012 /* method ropes#RopeBufferBytes#[] for (self: SequenceRead[nullable Object], Int): nullable Object */
2013 val* VIRTUAL_core___core__RopeBufferBytes___core__abstract_collection__SequenceRead___91d_93d(val* self, long p0) {
2014 val* var /* : nullable Object */;
2015 unsigned char var1 /* : Byte */;
2016 val* var2 /* : nullable Object */;
2017 var1 = core___core__RopeBufferBytes___core__abstract_collection__SequenceRead___91d_93d(self, p0);
2018 var2 = BOX_core__Byte(var1); /* autobox from Byte to nullable Object */
2019 var = var2;
2020 RET_LABEL:;
2021 return var;
2022 }
2023 /* method ropes#RopeBufferBytes#iterator_from for (self: RopeBufferBytes, Int): IndexedIterator[Byte] */
2024 val* core___core__RopeBufferBytes___core__abstract_collection__SequenceRead__iterator_from(val* self, long p0) {
2025 val* var /* : IndexedIterator[Byte] */;
2026 long var_i /* var i: Int */;
2027 val* var1 /* : RopeBufferByteIterator */;
2028 val* var2 /* : Text */;
2029 val* var4 /* : Text */;
2030 var_i = p0;
2031 var1 = NEW_core__RopeBufferByteIterator(&type_core__RopeBufferByteIterator);
2032 {
2033 { /* Inline abstract_text#StringByteView#target (self) on <self:RopeBufferBytes> */
2034 var4 = self->attrs[COLOR_core__abstract_text__StringByteView___target].val; /* _target on <self:RopeBufferBytes> */
2035 if (unlikely(var4 == NULL)) {
2036 PRINT_ERROR("Runtime error: %s", "Uninitialized attribute _target");
2037 PRINT_ERROR(" (%s:%d)\n", FILE_core__abstract_text, 1156);
2038 fatal_exit(1);
2039 }
2040 var2 = var4;
2041 RET_LABEL3:(void)0;
2042 }
2043 }
2044 {
2045 core___core__RopeBufferByteIterator___from(var1, var2, var_i); /* Direct call ropes#RopeBufferByteIterator#from on <var1:RopeBufferByteIterator>*/
2046 }
2047 var = var1;
2048 goto RET_LABEL;
2049 RET_LABEL:;
2050 return var;
2051 }
2052 /* method ropes#RopeBufferBytes#reverse_iterator_from for (self: RopeBufferBytes, Int): IndexedIterator[Byte] */
2053 val* core___core__RopeBufferBytes___core__abstract_collection__SequenceRead__reverse_iterator_from(val* self, long p0) {
2054 val* var /* : IndexedIterator[Byte] */;
2055 long var_i /* var i: Int */;
2056 val* var1 /* : RopeBufferByteReverseIterator */;
2057 val* var2 /* : Text */;
2058 val* var4 /* : Text */;
2059 var_i = p0;
2060 var1 = NEW_core__RopeBufferByteReverseIterator(&type_core__RopeBufferByteReverseIterator);
2061 {
2062 { /* Inline abstract_text#StringByteView#target (self) on <self:RopeBufferBytes> */
2063 var4 = self->attrs[COLOR_core__abstract_text__StringByteView___target].val; /* _target on <self:RopeBufferBytes> */
2064 if (unlikely(var4 == NULL)) {
2065 PRINT_ERROR("Runtime error: %s", "Uninitialized attribute _target");
2066 PRINT_ERROR(" (%s:%d)\n", FILE_core__abstract_text, 1156);
2067 fatal_exit(1);
2068 }
2069 var2 = var4;
2070 RET_LABEL3:(void)0;
2071 }
2072 }
2073 {
2074 core___core__RopeBufferByteReverseIterator___from(var1, var2, var_i); /* Direct call ropes#RopeBufferByteReverseIterator#from on <var1:RopeBufferByteReverseIterator>*/
2075 }
2076 var = var1;
2077 goto RET_LABEL;
2078 RET_LABEL:;
2079 return var;
2080 }
2081 /* method ropes#Sys#maxlen for (self: Sys): Int */
2082 long core__ropes___Sys___maxlen(val* self) {
2083 long var /* : Int */;
2084 var = 64l;
2085 goto RET_LABEL;
2086 RET_LABEL:;
2087 return var;
2088 }