This commit is contained in:
Ginger Bill
2017-06-07 22:09:16 +01:00
parent f60c772c11
commit 574b82c0c7
9 changed files with 224 additions and 33 deletions
+2 -2
View File
@@ -158,8 +158,8 @@ AllocatorMode :: enum u8 {
Resize,
}
AllocatorProc :: #type proc(allocator_data: rawptr, mode: AllocatorMode,
size, alignment: int,
old_memory: rawptr, old_size: int, flags: u64) -> rawptr;
size, alignment: int,
old_memory: rawptr, old_size: int, flags: u64) -> rawptr;
Allocator :: struct #ordered {
procedure: AllocatorProc,
data: rawptr,
+2 -2
View File
@@ -27,8 +27,8 @@ __i128_quo_mod :: proc(a, b: i128, rem: ^i128) -> (quo: i128) #cc_odin #link_nam
s = a >> 127;
b = (a~s) - s;
urem: u128;
uquo := __u128_quo_mod(transmute(u128, a), transmute(u128, b), &urem);
uquo: u128;
urem := __u128_quo_mod(transmute(u128, a), transmute(u128, b), &uquo);
iquo := transmute(i128, uquo);
irem := transmute(i128, urem);
+1 -1
View File
@@ -1023,7 +1023,7 @@ fmt_arg :: proc(fi: ^FmtInfo, arg: any, verb: rune) {
case i16: fmt_int(fi, u128(a), true, 16, verb);
case i32: fmt_int(fi, u128(a), true, 32, verb);
case i64: fmt_int(fi, u128(a), true, 64, verb);
case i128: fmt_int(fi, u128(a), false, 128, verb);
case i128: fmt_int(fi, u128(a), true, 128, verb);
case uint: fmt_int(fi, u128(a), false, 8*size_of(uint), verb);
case u8: fmt_int(fi, u128(a), false, 8, verb);