authorgravatar for marc@tiehu.isMarc Tiehuis <marc@tiehu.is> 2024-07-14 00:46:16+12:00
committergravatar for marc@tiehu.isMarc Tiehuis <marc@tiehu.is> 2024-07-14 11:19:34+12:00
log944c6d40ce520f345450a15006498dd760fc3d3a
treee28b532532657b1ff7f3f26b8ca380223d7e55c4
parent8ff01f78f314a743df8c8f085a02416bb1ce0c72

std.fmt.formatFloat: skip f80 round-trip tests on x86_64 windows


1 files changed, 4 insertions(+), 0 deletions(-)

lib/std/fmt/format_float.zig+4
...@@ -1513,6 +1513,8 @@ const FLOAT128_POW5_INV_ERRORS: [154]u64 = .{...@@ -1513,6 +1513,8 @@ const FLOAT128_POW5_INV_ERRORS: [154]u64 = .{
15131513
1514// zig fmt: on1514// zig fmt: on
15151515
1516const builtin = @import("builtin");
1517
1516fn check(comptime T: type, value: T, comptime expected: []const u8) !void {1518fn check(comptime T: type, value: T, comptime expected: []const u8) !void {
1517 const I = @Type(.{ .Int = .{ .signedness = .unsigned, .bits = @bitSizeOf(T) } });1519 const I = @Type(.{ .Int = .{ .signedness = .unsigned, .bits = @bitSizeOf(T) } });
15181520
...@@ -1521,6 +1523,8 @@ fn check(comptime T: type, value: T, comptime expected: []const u8) !void {...@@ -1521,6 +1523,8 @@ fn check(comptime T: type, value: T, comptime expected: []const u8) !void {
1521 const s = try formatFloat(&buf, value, .{});1523 const s = try formatFloat(&buf, value, .{});
1522 try std.testing.expectEqualStrings(expected, s);1524 try std.testing.expectEqualStrings(expected, s);
15231525
1526 if (T == f80 and builtin.target.os.tag == .windows and builtin.target.cpu.arch == .x86_64) return;
1527
1524 const o = try std.fmt.parseFloat(T, s);1528 const o = try std.fmt.parseFloat(T, s);
1525 const o_bits: I = @bitCast(o);1529 const o_bits: I = @bitCast(o);
15261530