authorgravatar for mlugg@mlugg.co.ukMatthew Lugg <mlugg@mlugg.co.uk> 2026-03-28 19:24:09+00:00
committergravatar for mlugg@mlugg.co.ukMatthew Lugg <mlugg@mlugg.co.uk> 2026-03-28 19:25:01+00:00
logabaf3dfbe9b79dcdaf742fa1c08ce6f54061e237
tree9f90bfbd615dbaeee77cdb4e1dd1b00fdf99381f
parentb36cfc6352df4c5c5005c7a720dbc84894097d11
signaturelock-open Commit is signed but in an unrecognized format.

tests: fix `wouldUseLlvm` on x86_64-windows


1 files changed, 9 insertions(+), 2 deletions(-)

test/tests.zig+9-2
...@@ -2647,12 +2647,19 @@ pub fn wouldUseLlvm(use_llvm: ?bool, query: std.Target.Query, optimize_mode: Opt...@@ -2647,12 +2647,19 @@ pub fn wouldUseLlvm(use_llvm: ?bool, query: std.Target.Query, optimize_mode: Opt
2647 }2647 }
2648 const cpu_arch = query.cpu_arch orelse builtin.cpu.arch;2648 const cpu_arch = query.cpu_arch orelse builtin.cpu.arch;
2649 const os_tag = query.os_tag orelse builtin.os.tag;2649 const os_tag = query.os_tag orelse builtin.os.tag;
2650 const ofmt: std.Target.ObjectFormat = query.ofmt orelse .default(os_tag, cpu_arch);
2650 switch (cpu_arch) {2651 switch (cpu_arch) {
2651 .x86_64 => if (os_tag.isBSD() or os_tag == .illumos or std.Target.ptrBitWidth_arch_abi(cpu_arch, query.abi orelse .none) != 64) return true,2652 .x86_64 => {
2653 if (std.Target.ptrBitWidth_arch_abi(cpu_arch, query.abi orelse .none) != 64) return true;
2654 if (os_tag.isBSD() or os_tag == .illumos) return true;
2655 return switch (ofmt) {
2656 .elf, .macho => return false,
2657 else => return true,
2658 };
2659 },
2652 .spirv32, .spirv64 => return false,2660 .spirv32, .spirv64 => return false,
2653 else => return true,2661 else => return true,
2654 }2662 }
2655 return false;
2656}2663}
26572664
2658const CAbiTestOptions = struct {2665const CAbiTestOptions = struct {