commit a85cb728775375825afe4ebd62c60ae0b361d1e9 (tree)
parent 9115f8838672021655f473ba44f33dcaf90b8371
Author: Alex Rønne Petersen <alex@alexrp.com>
Date: Sat, 6 Jun 2026 01:53:23 +0200
cbe: fix helper call generation for int types that lower to 128-bit ints
closes https://codeberg.org/ziglang/zig/issues/35639
Diffstat:
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/src/codegen/c.zig b/src/codegen/c.zig
@@ -1977,9 +1977,9 @@ pub const DeclGen = struct {
}
switch (CType.classifyInt(ty, zcu)) {
.void => unreachable, // opv
- .small => try w.print("{c}{d}", .{
+ .small => |s| try w.print("{c}{d}", .{
signAbbrev(ty.intInfo(zcu).signedness),
- ty.abiSize(zcu) * 8,
+ s.bits(zcu.getTarget()),
}),
.big => try w.writeAll("big"),
}