std.debug: don't use SelfInfo.Windows for UEFI

It is, in fact, Windows-only.
This commit is contained in:
Alex Rønne Petersen 2025-10-01 15:33:50 +02:00
parent 59633e54a2
commit e1fb662f60
No known key found for this signature in database

View File

@ -62,7 +62,7 @@ pub const cpu_context = @import("debug/cpu_context.zig");
pub const SelfInfo = if (@hasDecl(root, "debug") and @hasDecl(root.debug, "SelfInfo"))
root.debug.SelfInfo
else switch (std.Target.ObjectFormat.default(native_os, native_arch)) {
.coff => @import("debug/SelfInfo/Windows.zig"),
.coff => if (native_os == .windows) @import("debug/SelfInfo/Windows.zig") else void,
.elf => @import("debug/SelfInfo/Elf.zig"),
.macho => @import("debug/SelfInfo/Darwin.zig"),
.goff, .plan9, .spirv, .wasm, .xcoff => void,