aboutsummaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
authorxdBronch <51252236+xdBronch@users.noreply.github.com>2024-01-02 20:20:34 -0500
committerVeikka Tuominen <git@vexu.eu>2024-01-03 11:05:25 +0200
commitd03649ec2f42c6b967f7113e78aa137de5384c1a (patch)
treec2fca76f7f642b942f4076faf1ba64ccb3fb50b3 /test
parentca4ee9ae73559062da24937ef4a7376d9d27bbeb (diff)
downloadzig-d03649ec2f42c6b967f7113e78aa137de5384c1a.tar.gz
zig-d03649ec2f42c6b967f7113e78aa137de5384c1a.zip
add missing resolveStructFieldInits
Diffstat (limited to 'test')
-rw-r--r--test/behavior/tuple.zig8
1 files changed, 8 insertions, 0 deletions
diff --git a/test/behavior/tuple.zig b/test/behavior/tuple.zig
index 039a96d29f..303f3b2df5 100644
--- a/test/behavior/tuple.zig
+++ b/test/behavior/tuple.zig
@@ -480,3 +480,11 @@ test "empty tuple type" {
const s: S = .{};
try expect(s.len == 0);
}
+
+test "tuple with comptime fields with non empty initializer" {
+ if (builtin.zig_backend == .stage2_aarch64) return error.SkipZigTest; // TODO
+ if (builtin.zig_backend == .stage2_spirv64) return error.SkipZigTest;
+
+ const a: struct { comptime comptime_int = 0 } = .{0};
+ _ = a;
+}