diff options
| author | Andrew Kelley <andrew@ziglang.org> | 2023-01-22 00:36:50 -0500 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2023-01-22 00:36:50 -0500 |
| commit | a51c76541d60da81ef53e0ab1f221a80d9956bd5 (patch) | |
| tree | 023a1f1fbc02b646214b70d78dad0acb7ec158f3 /test/behavior/struct.zig | |
| parent | f85c01d4c7520d2242626f4c0684ab97e47af373 (diff) | |
| parent | aa626deadddcf26a5789d29d5ba88c978ee53b89 (diff) | |
| download | zig-a51c76541d60da81ef53e0ab1f221a80d9956bd5.tar.gz zig-a51c76541d60da81ef53e0ab1f221a80d9956bd5.zip | |
Merge pull request #14403 from Vexu/fixes
Misc fixes
Diffstat (limited to 'test/behavior/struct.zig')
| -rw-r--r-- | test/behavior/struct.zig | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/test/behavior/struct.zig b/test/behavior/struct.zig index a32a0ed495..ed3e1ce88f 100644 --- a/test/behavior/struct.zig +++ b/test/behavior/struct.zig @@ -1573,3 +1573,8 @@ test "struct fields get automatically reordered" { }; try expect(@sizeOf(S1) == @sizeOf(S2)); } + +test "directly initiating tuple like struct" { + const a = struct { u8 }{8}; + try expect(a[0] == 8); +} |
