aboutsummaryrefslogtreecommitdiff
path: root/test/behavior/bugs/11159.zig
blob: 02cccf3e0aa41d80447985b8084e5093deecd6df (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
const std = @import("std");
const builtin = @import("builtin");

test {
    const T = @TypeOf(.{ @as(i32, 0), @as(u32, 0) });
    var a: T = .{ 0, 0 };
    _ = a;
}

test {
    if (builtin.zig_backend == .stage1) return error.SkipZigTest; // TODO
    if (builtin.zig_backend == .stage2_c) return error.SkipZigTest; // TODO

    const S = struct {
        comptime x: i32 = 0,
        comptime y: u32 = 0,
    };
    var a: S = .{};
    _ = a;
    var b = S{};
    _ = b;
}