From c0cc0f5991abbe2cadc769b2a87be105be681181 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Alex=20R=C3=B8nne=20Petersen?= Date: Mon, 19 Oct 2026 06:58:23 +0200 Subject: [PATCH] std.Target: fix cTypeBitSize() for ez80-freestanding It was incorrectly using the generic prong. Just throw tios in the same OS prong as freestanding and ashetos. --- lib/std/Target.zig | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/lib/std/Target.zig b/lib/std/Target.zig index c99e5e4fe592957eb5a6fb7e95397d38694bf8b5..9019b913b2f0916b840a036b8d239f4c9e95843e 100644 --- a/lib/std/Target.zig +++ b/lib/std/Target.zig @@ -3232,6 +3232,7 @@ pub fn cTypeBitSize(target: *const Target, c_type: CType) ?u16 { .freestanding, .other, .ashetos, + .tios, => switch (target.cpu.arch) { .msp430, .x86_16, @@ -3254,6 +3255,13 @@ pub fn cTypeBitSize(target: *const Target, c_type: CType) ?u16 { .long, .ulong, .float => 32, .double, .longdouble, .longlong, .ulonglong => 64, }, + .ez80 => switch (c_type) { + .char => 8, + .short, .ushort => 16, + .int, .uint => 24, + .long, .ulong, .float, .double => 32, + .longlong, .ulonglong, .longdouble => 64, + }, else => switch (c_type) { .char => 8, .short, .ushort => 16, @@ -3475,14 +3483,6 @@ pub fn cTypeBitSize(target: *const Target, c_type: CType) ?u16 { .longdouble => 80, }, - .tios => switch (c_type) { - .char => 8, - .short, .ushort => 16, - .int, .uint => 24, - .long, .ulong, .float, .double => 32, - .longlong, .ulonglong, .longdouble => 64, - }, - .opengl => null, }; } -- 2.54.0