From e1d8187028ec6df7fbf420d3e4b56da8bf3dcf0a Mon Sep 17 00:00:00 2001 From: mlugg Date: Tue, 5 Mar 2024 09:45:58 +0000 Subject: cases: correct after #18816 I changed an error messages and fixed a minor bug while implementing this proposal, which led to a few compile error cases failing. --- test/cases/compile_errors/reify_struct.zig | 2 +- .../reify_type_for_tagged_union_with_extra_enum_field.zig | 2 +- .../compile_errors/reify_type_for_tagged_union_with_no_union_fields.zig | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) (limited to 'test') diff --git a/test/cases/compile_errors/reify_struct.zig b/test/cases/compile_errors/reify_struct.zig index f20ea15048..3d11d42996 100644 --- a/test/cases/compile_errors/reify_struct.zig +++ b/test/cases/compile_errors/reify_struct.zig @@ -74,7 +74,7 @@ comptime { // target=native // // :2:5: error: tuple cannot have non-numeric field 'foo' -// :16:5: error: tuple field 3 exceeds tuple field count +// :16:5: error: tuple field name '3' does not match field index 0 // :30:5: error: comptime field without default initialization value // :44:5: error: extern struct fields cannot be marked comptime // :58:5: error: alignment in a packed struct field must be set to 0 diff --git a/test/cases/compile_errors/reify_type_for_tagged_union_with_extra_enum_field.zig b/test/cases/compile_errors/reify_type_for_tagged_union_with_extra_enum_field.zig index 96da0752df..b32100ab73 100644 --- a/test/cases/compile_errors/reify_type_for_tagged_union_with_extra_enum_field.zig +++ b/test/cases/compile_errors/reify_type_for_tagged_union_with_extra_enum_field.zig @@ -30,6 +30,6 @@ export fn entry() void { // backend=stage2 // target=native // -// :13:16: error: enum field(s) missing in union +// :13:16: error: enum fields missing in union // :1:13: note: field 'arst' missing, declared here // :1:13: note: enum declared here diff --git a/test/cases/compile_errors/reify_type_for_tagged_union_with_no_union_fields.zig b/test/cases/compile_errors/reify_type_for_tagged_union_with_no_union_fields.zig index 3c29083418..4023ebd74f 100644 --- a/test/cases/compile_errors/reify_type_for_tagged_union_with_no_union_fields.zig +++ b/test/cases/compile_errors/reify_type_for_tagged_union_with_no_union_fields.zig @@ -26,7 +26,7 @@ export fn entry() void { // backend=stage2 // target=native // -// :12:16: error: enum field(s) missing in union +// :12:16: error: enum fields missing in union // :1:13: note: field 'signed' missing, declared here // :1:13: note: field 'unsigned' missing, declared here // :1:13: note: enum declared here -- cgit v1.2.3