diff options
| author | Alex Rønne Petersen <alex@alexrp.com> | 2025-09-26 16:01:43 +0200 |
|---|---|---|
| committer | Alex Rønne Petersen <alex@alexrp.com> | 2025-09-26 16:20:15 +0200 |
| commit | 4c798bb0bd0043459f5b979ab3dfaee9a6f5ac97 (patch) | |
| tree | 245bbc56c70be7cebdf77f9c780008afe18d8906 /lib/std/builtin.zig | |
| parent | be2482146401d69e59b218443601c46838cd5ee5 (diff) | |
| download | zig-4c798bb0bd0043459f5b979ab3dfaee9a6f5ac97.tar.gz zig-4c798bb0bd0043459f5b979ab3dfaee9a6f5ac97.zip | |
std.builtin: define VaList as `struct { __ap: *anyopaque }` for Arm per AAPCS
Diffstat (limited to 'lib/std/builtin.zig')
| -rw-r--r-- | lib/std/builtin.zig | 11 |
1 files changed, 7 insertions, 4 deletions
diff --git a/lib/std/builtin.zig b/lib/std/builtin.zig index e942f9877f..ca7d9e251a 100644 --- a/lib/std/builtin.zig +++ b/lib/std/builtin.zig @@ -846,6 +846,12 @@ pub const VaListAarch64 = extern struct { /// This data structure is used by the Zig language code generation and /// therefore must be kept in sync with the compiler implementation. +pub const VaListArm = extern struct { + __ap: *anyopaque, +}; + +/// This data structure is used by the Zig language code generation and +/// therefore must be kept in sync with the compiler implementation. pub const VaListHexagon = extern struct { __gpr: c_long, __fpr: c_long, @@ -899,10 +905,7 @@ pub const VaList = switch (builtin.cpu.arch) { .stage2_llvm => @compileError("disabled due to miscompilations"), }, }, - .arm, .armeb, .thumb, .thumbeb => switch (builtin.os.tag) { - .ios, .macos, .tvos, .watchos, .visionos => *u8, - else => *anyopaque, - }, + .arm, .armeb, .thumb, .thumbeb => VaListArm, .amdgcn => *u8, .avr => *anyopaque, .bpfel, .bpfeb => *anyopaque, |
