diff options
Diffstat (limited to 'doc/langref/test_error_union.zig')
| -rw-r--r-- | doc/langref/test_error_union.zig | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/doc/langref/test_error_union.zig b/doc/langref/test_error_union.zig index 918c7e98f3..0cc01ec4a4 100644 --- a/doc/langref/test_error_union.zig +++ b/doc/langref/test_error_union.zig @@ -10,10 +10,10 @@ test "error union" { foo = error.SomeError; // Use compile-time reflection to access the payload type of an error union: - try comptime expect(@typeInfo(@TypeOf(foo)).ErrorUnion.payload == i32); + try comptime expect(@typeInfo(@TypeOf(foo)).error_union.payload == i32); // Use compile-time reflection to access the error set type of an error union: - try comptime expect(@typeInfo(@TypeOf(foo)).ErrorUnion.error_set == anyerror); + try comptime expect(@typeInfo(@TypeOf(foo)).error_union.error_set == anyerror); } // test |
