authorgravatar for luuk@degram.devLuuk de Gram <luuk@degram.dev> 2022-08-26 22:00:22+02:00
committergravatar for luuk@degram.devLuuk de Gram <luuk@degram.dev> 2022-08-28 17:50:07+02:00
log1eb22e7ad6f700a72d34cdb36e614c95bdab0464
tree3ed8ffa65e6798d6d18986c0ee08a4ae332da9af
parent91dba79c48f0a309e014062f2fe311a5c46b1084
signaturelock-open Commit is signed but in an unrecognized format.

wasm: skip unimplemented behavior test

Since now the size of a c_longdouble is correctly 16 bytes, the test is no longer passing. It was previously accidentally passing due to incorrect sizing and it not being larger than the size of a f64. disable long_double test for windows

2 files changed, 7 insertions(+), 0 deletions(-)

test/behavior/cast.zig+1
......@@ -1430,6 +1430,7 @@ test "coerce between pointers of compatible differently-named floats" {
14301430 if (builtin.zig_backend == .stage2_aarch64) return error.SkipZigTest; // TODO
14311431 if (builtin.zig_backend == .stage2_arm) return error.SkipZigTest; // TODO
14321432 if (builtin.zig_backend == .stage2_x86_64) return error.SkipZigTest; // TODO
1433 if (builtin.zig_backend == .stage2_wasm) return error.SkipZigTest; // TODO
14331434
14341435 if (builtin.os.tag == .windows) {
14351436 // https://github.com/ziglang/zig/issues/12396
test/c_abi/main.zig+6
......@@ -1,4 +1,5 @@
11const std = @import("std");
2const builtin = @import("builtin");
23const print = std.debug.print;
34const expect = std.testing.expect;
45
......@@ -106,6 +107,10 @@ test "C ABI floats" {
106107 c_f32(12.34);
107108 c_f64(56.78);
108109 c_five_floats(1.0, 2.0, 3.0, 4.0, 5.0);
110}
111
112test "C ABI long double" {
113 if (!builtin.cpu.arch.isWasm()) return error.SkipZigTest;
109114 c_long_double(12.34);
110115}
111116
......@@ -116,6 +121,7 @@ export fn zig_f64(x: f64) void {
116121 expect(x == 56.78) catch @panic("test failure: zig_f64");
117122}
118123export fn zig_longdouble(x: c_longdouble) void {
124 if (!builtin.cpu.arch.isWasm()) return; // waiting for #1481
119125 expect(x == 12.34) catch @panic("test failure: zig_longdouble");
120126}
121127