#zig build-obj {
--name test -fno-emit-bin
-Mroot=test.zig
#}

#write test.zig {
export fn entry1() void {
    const S = extern struct { x: u32 };
    _ = *align(1:2:8) S;
}

export fn entry2() void {
    const S = struct { x: u32 };
    _ = *align(1:2:@sizeOf(S) * 2) S;
}

export fn entry3() void {
    const E = enum { implicit, backing, type };
    _ = *align(1:2:8) E;
}
#}
#update
#check errors {
test.zig:3:23: error: bit-pointer cannot refer to value of type 'test.entry1.S'
test.zig:3:23: note: non-packed structs do not have a bit-packed representation
test.zig:2:22: note: struct declared here
test.zig:8:36: error: bit-pointer cannot refer to value of type 'test.entry2.S'
test.zig:8:36: note: non-packed structs do not have a bit-packed representation
test.zig:7:15: note: struct declared here
test.zig:13:23: error: bit-pointer cannot refer to value of type 'test.entry3.E'
test.zig:12:15: note: integer tag type of enum is inferred
test.zig:12:15: note: consider explicitly specifying the integer tag type
#}
