| ... | @@ -1046,7 +1046,7 @@ pub const Value = extern union { | ... | @@ -1046,7 +1046,7 @@ pub const Value = extern union { |
| 1046 | var bigint_buffer: BigIntSpace = undefined; | 1046 | var bigint_buffer: BigIntSpace = undefined; |
| 1047 | const bigint = val.toBigInt(&bigint_buffer); | 1047 | const bigint = val.toBigInt(&bigint_buffer); |
| 1048 | const bits = ty.intInfo(target).bits; | 1048 | const bits = ty.intInfo(target).bits; |
| 1049 | const abi_size = ty.abiSize(target); | 1049 | const abi_size = @intCast(usize, ty.abiSize(target)); |
| 1050 | bigint.writeTwosComplement(buffer, bits, abi_size, target.cpu.arch.endian()); | 1050 | bigint.writeTwosComplement(buffer, bits, abi_size, target.cpu.arch.endian()); |
| 1051 | }, | 1051 | }, |
| 1052 | .Enum => { | 1052 | .Enum => { |
| ... | @@ -1055,7 +1055,7 @@ pub const Value = extern union { | ... | @@ -1055,7 +1055,7 @@ pub const Value = extern union { |
| 1055 | var bigint_buffer: BigIntSpace = undefined; | 1055 | var bigint_buffer: BigIntSpace = undefined; |
| 1056 | const bigint = int_val.toBigInt(&bigint_buffer); | 1056 | const bigint = int_val.toBigInt(&bigint_buffer); |
| 1057 | const bits = ty.intInfo(target).bits; | 1057 | const bits = ty.intInfo(target).bits; |
| 1058 | const abi_size = ty.abiSize(target); | 1058 | const abi_size = @intCast(usize, ty.abiSize(target)); |
| 1059 | bigint.writeTwosComplement(buffer, bits, abi_size, target.cpu.arch.endian()); | 1059 | bigint.writeTwosComplement(buffer, bits, abi_size, target.cpu.arch.endian()); |
| 1060 | }, | 1060 | }, |
| 1061 | .Float => switch (ty.floatBits(target)) { | 1061 | .Float => switch (ty.floatBits(target)) { |
| ... | @@ -1098,7 +1098,7 @@ pub const Value = extern union { | ... | @@ -1098,7 +1098,7 @@ pub const Value = extern union { |
| 1098 | const Limb = std.math.big.Limb; | 1098 | const Limb = std.math.big.Limb; |
| 1099 | const limb_count = (buffer.len + @sizeOf(Limb) - 1) / @sizeOf(Limb); | 1099 | const limb_count = (buffer.len + @sizeOf(Limb) - 1) / @sizeOf(Limb); |
| 1100 | const limbs_buffer = try arena.alloc(Limb, limb_count); | 1100 | const limbs_buffer = try arena.alloc(Limb, limb_count); |
| 1101 | const abi_size = ty.abiSize(target); | 1101 | const abi_size = @intCast(usize, ty.abiSize(target)); |
| 1102 | var bigint = BigIntMutable.init(limbs_buffer, 0); | 1102 | var bigint = BigIntMutable.init(limbs_buffer, 0); |
| 1103 | bigint.readTwosComplement(buffer, int_info.bits, abi_size, endian, int_info.signedness); | 1103 | bigint.readTwosComplement(buffer, int_info.bits, abi_size, endian, int_info.signedness); |
| 1104 | return fromBigInt(arena, bigint.toConst()); | 1104 | return fromBigInt(arena, bigint.toConst()); |