aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorDavid Rubin <daviru007@icloud.com>2025-03-20 22:16:57 -0700
committerDavid Rubin <david@vortan.dev>2025-03-24 06:58:01 -0700
commitae442e2c2906f768098de307f3388ef0e8d47e5b (patch)
tree177ff5c8be5d31f88bcf0cb5142f43e6f31ce630 /src
parentadee3ee9a2c679069a15bd5476860d45f05b356b (diff)
downloadzig-ae442e2c2906f768098de307f3388ef0e8d47e5b.tar.gz
zig-ae442e2c2906f768098de307f3388ef0e8d47e5b.zip
big.int: return normalized results from `{add,sub}Carry`
Diffstat (limited to 'src')
-rw-r--r--src/Value.zig2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/Value.zig b/src/Value.zig
index 7357c0f225..7e9e13ef38 100644
--- a/src/Value.zig
+++ b/src/Value.zig
@@ -2223,7 +2223,7 @@ pub fn shlSatScalar(
const shift: usize = @intCast(rhs.toUnsignedInt(zcu));
const limbs = try arena.alloc(
std.math.big.Limb,
- std.math.big.int.calcTwosCompLimbCount(info.bits) + 1,
+ std.math.big.int.calcTwosCompLimbCount(info.bits),
);
var result_bigint = BigIntMutable{
.limbs = limbs,