zig

fork of https://codeberg.org/ziglang/zig
Log | Files | Refs | README | LICENSE

commit 7eae26d60895dc62fa62f6562a4eeecb8685aae5 (tree)
parent 0e37ff0d591dd75ceec9208196bec29efaec607a
Author: Andrew Kelley <andrew@ziglang.org>
Date:   Sun, 29 Jun 2025 19:35:29 -0700

delete bad behavior test

behavior tests must not depend on std.io

Diffstat:
Mtest/behavior/error.zig | 18------------------
1 file changed, 0 insertions(+), 18 deletions(-)

diff --git a/test/behavior/error.zig b/test/behavior/error.zig @@ -1032,24 +1032,6 @@ test "function called at runtime is properly analyzed for inferred error set" { }; } -test "generic type constructed from inferred error set of unresolved function" { - if (builtin.zig_backend == .stage2_arm) return error.SkipZigTest; - if (builtin.zig_backend == .stage2_aarch64) return error.SkipZigTest; - if (builtin.zig_backend == .stage2_sparc64) return error.SkipZigTest; // TODO - - const S = struct { - fn write(_: void, bytes: []const u8) !usize { - _ = bytes; - return 0; - } - const T = std.io.Writer(void, @typeInfo(@typeInfo(@TypeOf(write)).@"fn".return_type.?).error_union.error_set, write); - fn writer() T { - return .{ .context = {} }; - } - }; - _ = std.io.multiWriter(.{S.writer()}); -} - test "errorCast to adhoc inferred error set" { const S = struct { inline fn baz() !i32 {