aboutsummaryrefslogtreecommitdiff
path: root/lib/std/leb128.zig
diff options
context:
space:
mode:
authorEric Joldasov <bratishkaerik@getgoogleoff.me>2023-06-15 13:14:16 +0600
committerAndrew Kelley <andrew@ziglang.org>2023-06-19 12:34:42 -0700
commit50339f595aa6ec96760b1cd9f8d0e0bfc3f167fc (patch)
tree9e2b95d8e111e905e00511962dfd32c8e5bb3245 /lib/std/leb128.zig
parenta6c8ee5231230947c928bbe1c6a39eb6e1bb9c5b (diff)
downloadzig-50339f595aa6ec96760b1cd9f8d0e0bfc3f167fc.tar.gz
zig-50339f595aa6ec96760b1cd9f8d0e0bfc3f167fc.zip
all: zig fmt and rename "@XToY" to "@YFromX"
Signed-off-by: Eric Joldasov <bratishkaerik@getgoogleoff.me>
Diffstat (limited to 'lib/std/leb128.zig')
-rw-r--r--lib/std/leb128.zig2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/std/leb128.zig b/lib/std/leb128.zig
index bc5955d16a..859d753a6a 100644
--- a/lib/std/leb128.zig
+++ b/lib/std/leb128.zig
@@ -318,7 +318,7 @@ fn test_write_leb128(value: anytype) !void {
if (@typeInfo(T).Int.bits <= 7) break :bn @as(u16, 1);
const unused_bits = if (value < 0) @clz(~value) else @clz(value);
- const used_bits: u16 = (@typeInfo(T).Int.bits - unused_bits) + @boolToInt(t_signed);
+ const used_bits: u16 = (@typeInfo(T).Int.bits - unused_bits) + @intFromBool(t_signed);
if (used_bits <= 7) break :bn @as(u16, 1);
break :bn ((used_bits + 6) / 7);
};