authorgravatar for andrew@ziglang.orgAndrew Kelley <andrew@ziglang.org> 2023-12-04 23:15:53-07:00
committergravatar for andrew@ziglang.orgAndrew Kelley <andrew@ziglang.org> 2024-01-01 17:51:18-07:00
log8d5da5558827d9152dc8453c87c41ac6519f8a05
tree5615d983aef1d1bc4b46608c54068b3f8bc92cb9
parent77420af9d01b1932a583fdcbfa169f2eb2b7c221

std.Target.Query: fix regression with windows os version range

somebody left a landmine here without even a comment to warn about it

1 files changed, 3 insertions(+), 1 deletions(-)

lib/std/Target/Query.zig+3-1
...@@ -460,7 +460,9 @@ pub fn zigTriple(self: Query, allocator: Allocator) Allocator.Error![]u8 {...@@ -460,7 +460,9 @@ pub fn zigTriple(self: Query, allocator: Allocator) Allocator.Error![]u8 {
460 try formatVersion(v, result.writer());460 try formatVersion(v, result.writer());
461 },461 },
462 .windows => |v| {462 .windows => |v| {
463 try result.writer().print("...{s}", .{v});463 // This is counting on a custom format() function defined on `WindowsVersion`
464 // to add a prefix '.' and make there be a total of three dots.
465 try result.writer().print("..{s}", .{v});
464 },466 },
465 }467 }
466 }468 }