3VAL idris_b8CopyForGC(VM *vm, VAL a) {
4 VAL cl = allocate(vm, sizeof(Closure), 1);
6 cl->info.bits8 = a->info.bits8;
10VAL idris_b16CopyForGC(VM *vm, VAL a) {
11 VAL cl = allocate(vm, sizeof(Closure), 1);
13 cl->info.bits16 = a->info.bits16;
17VAL idris_b32CopyForGC(VM *vm, VAL a) {
18 VAL cl = allocate(vm, sizeof(Closure), 1);
20 cl->info.bits32 = a->info.bits32;
24VAL idris_b64CopyForGC(VM *vm, VAL a) {
25 VAL cl = allocate(vm, sizeof(Closure), 1);
27 cl->info.bits64 = a->info.bits64;
31VAL idris_b8(VM *vm, VAL a) {
32 VAL cl = allocate(vm, sizeof(Closure), 0);
34 cl->info.bits8 = (uint8_t) GETINT(a);
38VAL idris_b16(VM *vm, VAL a) {
39 VAL cl = allocate(vm, sizeof(Closure), 0);
41 cl->info.bits16 = (uint16_t) GETINT(a);
45VAL idris_b32(VM *vm, VAL a) {
46 VAL cl = allocate(vm, sizeof(Closure), 0);
48 cl->info.bits32 = (uint32_t) GETINT(a);
52VAL idris_b64(VM *vm, VAL a) {
53 VAL cl = allocate(vm, sizeof(Closure), 0);
55 cl->info.bits64 = (uint64_t) GETINT(a);
59VAL idris_castB32Int(VM *vm, VAL a) {
60 return MKINT(a->info.bits32);
63VAL idris_b8Plus(VM *vm, VAL a, VAL b) {
64 VAL cl = allocate(vm, sizeof(Closure), 0);
66 cl->info.bits8 = a->info.bits8 + b->info.bits8;
70VAL idris_b8Minus(VM *vm, VAL a, VAL b) {
71 VAL cl = allocate(vm, sizeof(Closure), 0);
73 cl->info.bits8 = a->info.bits8 - b->info.bits8;
77VAL idris_b8Times(VM *vm, VAL a, VAL b) {
78 VAL cl = allocate(vm, sizeof(Closure), 0);
80 cl->info.bits8 = a->info.bits8 * b->info.bits8;
84VAL idris_b8UDiv(VM *vm, VAL a, VAL b) {
85 VAL cl = allocate(vm, sizeof(Closure), 0);
87 cl->info.bits8 = a->info.bits8 / b->info.bits8;
91VAL idris_b8SDiv(VM *vm, VAL a, VAL b) {
92 VAL cl = allocate(vm, sizeof(Closure), 0);
94 cl->info.bits8 = (uint8_t) (((int8_t) a->info.bits8) / ((int8_t) b->info.bits8));
98VAL idris_b8URem(VM *vm, VAL a, VAL b) {
99 VAL cl = allocate(vm, sizeof(Closure), 0);
101 cl->info.bits8 = a->info.bits8 % b->info.bits8;
105VAL idris_b8SRem(VM *vm, VAL a, VAL b) {
106 VAL cl = allocate(vm, sizeof(Closure), 0);
108 cl->info.bits8 = (uint8_t) (((int8_t) a->info.bits8) % ((int8_t) b->info.bits8));
112VAL idris_b8Lt(VM *vm, VAL a, VAL b) {
113 return MKINT(a->info.bits8 < b->info.bits8);
116VAL idris_b8Gt(VM *vm, VAL a, VAL b) {
117 return MKINT(a->info.bits8 > b->info.bits8);
120VAL idris_b8Eq(VM *vm, VAL a, VAL b) {
121 return MKINT(a->info.bits8 == b->info.bits8);
124VAL idris_b8Lte(VM *vm, VAL a, VAL b) {
125 return MKINT(a->info.bits8 <= b->info.bits8);
128VAL idris_b8Gte(VM *vm, VAL a, VAL b) {
129 return MKINT(a->info.bits8 >= b->info.bits8);
132VAL idris_b8Compl(VM *vm, VAL a) {
133 VAL cl = allocate(vm, sizeof(Closure), 0);
135 cl->info.bits8 = ~ a->info.bits8;
139VAL idris_b8And(VM *vm, VAL a, VAL b) {
140 VAL cl = allocate(vm, sizeof(Closure), 0);
142 cl->info.bits8 = a->info.bits8 & b->info.bits8;
146VAL idris_b8Or(VM *vm, VAL a, VAL b) {
147 VAL cl = allocate(vm, sizeof(Closure), 0);
149 cl->info.bits8 = a->info.bits8 | b->info.bits8;
153VAL idris_b8Xor(VM *vm, VAL a, VAL b) {
154 VAL cl = allocate(vm, sizeof(Closure), 0);
156 cl->info.bits8 = a->info.bits8 ^ b->info.bits8;
160VAL idris_b8Shl(VM *vm, VAL a, VAL b) {
161 VAL cl = allocate(vm, sizeof(Closure), 0);
163 cl->info.bits8 = a->info.bits8 << b->info.bits8;
167VAL idris_b8LShr(VM *vm, VAL a, VAL b) {
168 VAL cl = allocate(vm, sizeof(Closure), 0);
170 cl->info.bits8 = a->info.bits8 >> b->info.bits8;
174VAL idris_b8AShr(VM *vm, VAL a, VAL b) {
175 VAL cl = allocate(vm, sizeof(Closure), 0);
177 cl->info.bits8 = (uint8_t) (((int8_t)a->info.bits8) >> ((int8_t)b->info.bits8));
181VAL idris_b16Plus(VM *vm, VAL a, VAL b) {
182 VAL cl = allocate(vm, sizeof(Closure), 0);
184 cl->info.bits16 = a->info.bits16 + b->info.bits16;
188VAL idris_b16Minus(VM *vm, VAL a, VAL b) {
189 VAL cl = allocate(vm, sizeof(Closure), 0);
191 cl->info.bits16 = a->info.bits16 - b->info.bits16;
195VAL idris_b16Times(VM *vm, VAL a, VAL b) {
196 VAL cl = allocate(vm, sizeof(Closure), 0);
198 cl->info.bits16 = a->info.bits16 * b->info.bits16;
202VAL idris_b16UDiv(VM *vm, VAL a, VAL b) {
203 VAL cl = allocate(vm, sizeof(Closure), 0);
205 cl->info.bits16 = a->info.bits16 / b->info.bits16;
209VAL idris_b16SDiv(VM *vm, VAL a, VAL b) {
210 VAL cl = allocate(vm, sizeof(Closure), 0);
213 (uint16_t) (((int16_t) a->info.bits16) / ((int16_t) b->info.bits16));
217VAL idris_b16URem(VM *vm, VAL a, VAL b) {
218 VAL cl = allocate(vm, sizeof(Closure), 0);
220 cl->info.bits16 = a->info.bits16 % b->info.bits16;
224VAL idris_b16SRem(VM *vm, VAL a, VAL b) {
225 VAL cl = allocate(vm, sizeof(Closure), 0);
228 (uint16_t) (((int16_t) a->info.bits16) % ((int16_t) b->info.bits16));
232VAL idris_b16Lt(VM *vm, VAL a, VAL b) {
233 return MKINT(a->info.bits16 < b->info.bits16);
236VAL idris_b16Gt(VM *vm, VAL a, VAL b) {
237 return MKINT(a->info.bits16 > b->info.bits16);
240VAL idris_b16Eq(VM *vm, VAL a, VAL b) {
241 return MKINT(a->info.bits16 == b->info.bits16);
244VAL idris_b16Lte(VM *vm, VAL a, VAL b) {
245 return MKINT(a->info.bits16 <= b->info.bits16);
248VAL idris_b16Gte(VM *vm, VAL a, VAL b) {
249 return MKINT(a->info.bits16 >= b->info.bits16);
252VAL idris_b16Compl(VM *vm, VAL a) {
253 VAL cl = allocate(vm, sizeof(Closure), 0);
255 cl->info.bits16 = ~ a->info.bits16;
259VAL idris_b16And(VM *vm, VAL a, VAL b) {
260 VAL cl = allocate(vm, sizeof(Closure), 0);
262 cl->info.bits16 = a->info.bits16 & b->info.bits16;
266VAL idris_b16Or(VM *vm, VAL a, VAL b) {
267 VAL cl = allocate(vm, sizeof(Closure), 0);
269 cl->info.bits16 = a->info.bits16 | b->info.bits16;
273VAL idris_b16Xor(VM *vm, VAL a, VAL b) {
274 VAL cl = allocate(vm, sizeof(Closure), 0);
276 cl->info.bits16 = a->info.bits16 ^ b->info.bits16;
280VAL idris_b16Shl(VM *vm, VAL a, VAL b) {
281 VAL cl = allocate(vm, sizeof(Closure), 0);
283 cl->info.bits16 = a->info.bits16 << b->info.bits16;
287VAL idris_b16LShr(VM *vm, VAL a, VAL b) {
288 VAL cl = allocate(vm, sizeof(Closure), 0);
290 cl->info.bits16 = a->info.bits16 >> b->info.bits16;
294VAL idris_b16AShr(VM *vm, VAL a, VAL b) {
295 VAL cl = allocate(vm, sizeof(Closure), 0);
297 cl->info.bits16 = (uint16_t) (((int16_t)a->info.bits16) >> ((int16_t)b->info.bits16));
301VAL idris_b32Plus(VM *vm, VAL a, VAL b) {
302 VAL cl = allocate(vm, sizeof(Closure), 0);
304 cl->info.bits32 = a->info.bits32 + b->info.bits32;
308VAL idris_b32Minus(VM *vm, VAL a, VAL b) {
309 VAL cl = allocate(vm, sizeof(Closure), 0);
311 cl->info.bits32 = a->info.bits32 - b->info.bits32;
315VAL idris_b32Times(VM *vm, VAL a, VAL b) {
316 VAL cl = allocate(vm, sizeof(Closure), 0);
318 cl->info.bits32 = a->info.bits32 * b->info.bits32;
322VAL idris_b32UDiv(VM *vm, VAL a, VAL b) {
323 VAL cl = allocate(vm, sizeof(Closure), 0);
325 cl->info.bits32 = a->info.bits32 / b->info.bits32;
329VAL idris_b32SDiv(VM *vm, VAL a, VAL b) {
330 VAL cl = allocate(vm, sizeof(Closure), 0);
333 (uint32_t) (((int32_t) a->info.bits32) / ((int32_t) b->info.bits32));
337VAL idris_b32URem(VM *vm, VAL a, VAL b) {
338 VAL cl = allocate(vm, sizeof(Closure), 0);
340 cl->info.bits32 = a->info.bits32 % b->info.bits32;
344VAL idris_b32SRem(VM *vm, VAL a, VAL b) {
345 VAL cl = allocate(vm, sizeof(Closure), 0);
348 (uint32_t) (((int32_t) a->info.bits32) % ((int32_t) b->info.bits32));
352VAL idris_b32Lt(VM *vm, VAL a, VAL b) {
353 return MKINT(a->info.bits32 < b->info.bits32);
356VAL idris_b32Gt(VM *vm, VAL a, VAL b) {
357 return MKINT(a->info.bits32 > b->info.bits32);
360VAL idris_b32Eq(VM *vm, VAL a, VAL b) {
361 return MKINT(a->info.bits32 == b->info.bits32);
364VAL idris_b32Lte(VM *vm, VAL a, VAL b) {
365 return MKINT(a->info.bits32 <= b->info.bits32);
368VAL idris_b32Gte(VM *vm, VAL a, VAL b) {
369 return MKINT(a->info.bits32 >= b->info.bits32);
372VAL idris_b32Compl(VM *vm, VAL a) {
373 VAL cl = allocate(vm, sizeof(Closure), 0);
375 cl->info.bits32 = ~ a->info.bits32;
379VAL idris_b32And(VM *vm, VAL a, VAL b) {
380 VAL cl = allocate(vm, sizeof(Closure), 0);
382 cl->info.bits32 = a->info.bits32 & b->info.bits32;
386VAL idris_b32Or(VM *vm, VAL a, VAL b) {
387 VAL cl = allocate(vm, sizeof(Closure), 0);
389 cl->info.bits32 = a->info.bits32 | b->info.bits32;
393VAL idris_b32Xor(VM *vm, VAL a, VAL b) {
394 VAL cl = allocate(vm, sizeof(Closure), 0);
396 cl->info.bits32 = a->info.bits32 ^ b->info.bits32;
400VAL idris_b32Shl(VM *vm, VAL a, VAL b) {
401 VAL cl = allocate(vm, sizeof(Closure), 0);
403 cl->info.bits32 = a->info.bits32 << b->info.bits32;
407VAL idris_b32LShr(VM *vm, VAL a, VAL b) {
408 VAL cl = allocate(vm, sizeof(Closure), 0);
410 cl->info.bits32 = a->info.bits32 >> b->info.bits32;
414VAL idris_b32AShr(VM *vm, VAL a, VAL b) {
415 VAL cl = allocate(vm, sizeof(Closure), 0);
417 cl->info.bits32 = (uint32_t) (((int32_t)a->info.bits32) >> ((int32_t)b->info.bits32));
421VAL idris_b64Plus(VM *vm, VAL a, VAL b) {
422 VAL cl = allocate(vm, sizeof(Closure), 0);
424 cl->info.bits64 = a->info.bits64 + b->info.bits64;
428VAL idris_b64Minus(VM *vm, VAL a, VAL b) {
429 VAL cl = allocate(vm, sizeof(Closure), 0);
431 cl->info.bits64 = a->info.bits64 - b->info.bits64;
435VAL idris_b64Times(VM *vm, VAL a, VAL b) {
436 VAL cl = allocate(vm, sizeof(Closure), 0);
438 cl->info.bits64 = a->info.bits64 * b->info.bits64;
442VAL idris_b64UDiv(VM *vm, VAL a, VAL b) {
443 VAL cl = allocate(vm, sizeof(Closure), 0);
445 cl->info.bits64 = a->info.bits64 / b->info.bits64;
449VAL idris_b64SDiv(VM *vm, VAL a, VAL b) {
450 VAL cl = allocate(vm, sizeof(Closure), 0);
453 (uint64_t) (((int64_t) a->info.bits64) / ((int64_t) b->info.bits64));
457VAL idris_b64URem(VM *vm, VAL a, VAL b) {
458 VAL cl = allocate(vm, sizeof(Closure), 0);
460 cl->info.bits64 = a->info.bits64 % b->info.bits64;
464VAL idris_b64SRem(VM *vm, VAL a, VAL b) {
465 VAL cl = allocate(vm, sizeof(Closure), 0);
468 (uint64_t) (((int64_t) a->info.bits64) % ((int64_t) b->info.bits64));
472VAL idris_b64Lt(VM *vm, VAL a, VAL b) {
473 return MKINT(a->info.bits64 < b->info.bits64);
476VAL idris_b64Gt(VM *vm, VAL a, VAL b) {
477 return MKINT(a->info.bits64 > b->info.bits64);
480VAL idris_b64Eq(VM *vm, VAL a, VAL b) {
481 return MKINT(a->info.bits64 == b->info.bits64);
484VAL idris_b64Lte(VM *vm, VAL a, VAL b) {
485 return MKINT(a->info.bits64 <= b->info.bits64);
488VAL idris_b64Gte(VM *vm, VAL a, VAL b) {
489 return MKINT(a->info.bits64 >= b->info.bits64);
492VAL idris_b64Compl(VM *vm, VAL a) {
493 VAL cl = allocate(vm, sizeof(Closure), 0);
495 cl->info.bits64 = ~ a->info.bits64;
499VAL idris_b64And(VM *vm, VAL a, VAL b) {
500 VAL cl = allocate(vm, sizeof(Closure), 0);
502 cl->info.bits64 = a->info.bits64 & b->info.bits64;
506VAL idris_b64Or(VM *vm, VAL a, VAL b) {
507 VAL cl = allocate(vm, sizeof(Closure), 0);
509 cl->info.bits64 = a->info.bits64 | b->info.bits64;
513VAL idris_b64Xor(VM *vm, VAL a, VAL b) {
514 VAL cl = allocate(vm, sizeof(Closure), 0);
516 cl->info.bits64 = a->info.bits64 ^ b->info.bits64;
520VAL idris_b64Shl(VM *vm, VAL a, VAL b) {
521 VAL cl = allocate(vm, sizeof(Closure), 0);
523 cl->info.bits64 = a->info.bits64 << b->info.bits64;
527VAL idris_b64LShr(VM *vm, VAL a, VAL b) {
528 VAL cl = allocate(vm, sizeof(Closure), 0);
530 cl->info.bits64 = a->info.bits64 >> b->info.bits64;
534VAL idris_b64AShr(VM *vm, VAL a, VAL b) {
535 VAL cl = allocate(vm, sizeof(Closure), 0);
537 cl->info.bits64 = (uint64_t) (((int64_t)a->info.bits64) >> ((int64_t)b->info.bits64));
541VAL idris_b8Z16(VM *vm, VAL a) {
542 VAL cl = allocate(vm, sizeof(Closure), 0);
544 cl->info.bits16 = (uint16_t) a->info.bits8;
548VAL idris_b8Z32(VM *vm, VAL a) {
549 VAL cl = allocate(vm, sizeof(Closure), 0);
551 cl->info.bits32 = (uint32_t) a->info.bits8;
555VAL idris_b8Z64(VM *vm, VAL a) {
556 VAL cl = allocate(vm, sizeof(Closure), 0);
558 cl->info.bits64 = (uint64_t) a->info.bits8;
562VAL idris_b8S16(VM *vm, VAL a) {
563 VAL cl = allocate(vm, sizeof(Closure), 0);
565 cl->info.bits16 = (uint16_t) (int16_t) (int8_t) a->info.bits8;
569VAL idris_b8S32(VM *vm, VAL a) {
570 VAL cl = allocate(vm, sizeof(Closure), 0);
572 cl->info.bits32 = (uint32_t) (int32_t) (int8_t) a->info.bits8;
576VAL idris_b8S64(VM *vm, VAL a) {
577 VAL cl = allocate(vm, sizeof(Closure), 0);
579 cl->info.bits64 = (uint64_t) (int64_t) (int8_t) a->info.bits8;
583VAL idris_b16Z32(VM *vm, VAL a) {
584 VAL cl = allocate(vm, sizeof(Closure), 0);
586 cl->info.bits32 = (uint32_t) a->info.bits16;
590VAL idris_b16Z64(VM *vm, VAL a) {
591 VAL cl = allocate(vm, sizeof(Closure), 0);
593 cl->info.bits64 = (uint64_t) a->info.bits16;
597VAL idris_b16S32(VM *vm, VAL a) {
598 VAL cl = allocate(vm, sizeof(Closure), 0);
600 cl->info.bits32 = (uint32_t) (int32_t) (int16_t) a->info.bits16;
604VAL idris_b16S64(VM *vm, VAL a) {
605 VAL cl = allocate(vm, sizeof(Closure), 0);
607 cl->info.bits64 = (uint64_t) (int64_t) (int16_t) a->info.bits16;
611VAL idris_b16T8(VM *vm, VAL a) {
612 VAL cl = allocate(vm, sizeof(Closure), 0);
614 cl->info.bits8 = (uint8_t) a->info.bits16;
618VAL idris_b32Z64(VM *vm, VAL a) {
619 VAL cl = allocate(vm, sizeof(Closure), 0);
621 cl->info.bits64 = (uint64_t) a->info.bits32;
625VAL idris_b32S64(VM *vm, VAL a) {
626 VAL cl = allocate(vm, sizeof(Closure), 0);
628 cl->info.bits64 = (uint64_t) (int64_t) (int32_t) a->info.bits32;
632VAL idris_b32T8(VM *vm, VAL a) {
633 VAL cl = allocate(vm, sizeof(Closure), 0);
635 cl->info.bits8 = (uint8_t) a->info.bits32;
639VAL idris_b32T16(VM *vm, VAL a) {
640 VAL cl = allocate(vm, sizeof(Closure), 0);
642 cl->info.bits16 = (uint16_t) a->info.bits32;
646VAL idris_b64T8(VM *vm, VAL a) {
647 VAL cl = allocate(vm, sizeof(Closure), 0);
649 cl->info.bits8 = (uint8_t) a->info.bits64;
653VAL idris_b64T16(VM *vm, VAL a) {
654 VAL cl = allocate(vm, sizeof(Closure), 0);
656 cl->info.bits16 = (uint16_t) a->info.bits64;
660VAL idris_b64T32(VM *vm, VAL a) {
661 VAL cl = allocate(vm, sizeof(Closure), 0);
663 cl->info.bits32 = (uint32_t) a->info.bits64;
keysesc to close
- j k
- move down, up
- enter
- open
- esc
- back, or up a level
- 1 2 3 4
- readme, files, commits, refs
- /
- filter
- y
- copy the clone command
- c
- compare the chosen commit with another (or shift-click both)
- ?
- show or hide this list