authorgravatar for git@vexu.euVeikka Tuominen <git@vexu.eu> 2021-05-08 15:11:06+03:00
committergravatar for git@vexu.euVeikka Tuominen <git@vexu.eu> 2021-05-08 15:18:13+03:00
log7437c47d55da4c73aba26327d1a140aaf6591d4a
treefea08b223d1fbad33924e4daa78edd64af69b0bd
parent08b6baca122698db0d8543c8953d543f318c6422

tests: work around miscompilation


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

test/stage1/behavior/struct.zig+4-3
...@@ -933,9 +933,10 @@ test "packed struct with undefined initializers" {...@@ -933,9 +933,10 @@ test "packed struct with undefined initializers" {
933 var p: P = undefined;933 var p: P = undefined;
934 p = P{ .a = 2, .b = 4, .c = 6 };934 p = P{ .a = 2, .b = 4, .c = 6 };
935 // Make sure the compiler doesn't touch the unprefixed fields.935 // Make sure the compiler doesn't touch the unprefixed fields.
936 try expectEqual(@as(u3, 2), p.a);936 // Use expect since i386-linux doesn't like expectEqual
937 try expectEqual(@as(u3, 4), p.b);937 try expect(p.a == 2);
938 try expectEqual(@as(u3, 6), p.c);938 try expect(p.b == 4);
939 try expect(p.c == 6);
939 }940 }
940 };941 };
941942