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

somebody left a landmine here without even a comment to warn about it
This commit is contained in:
Andrew Kelley 2023-12-04 23:15:53 -07:00
parent 77420af9d0
commit 8d5da55588

View File

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