aboutsummaryrefslogtreecommitdiff
path: root/test/cases/compile_errors/as_many_ptr_undefined.zig
blob: a866449e9a7f06f8eaa08369838207cfe8d6b2b2 (plain)
1
2
3
4
5
6
7
8
export fn entry1() void {
    const slice = @as([*]i32, undefined)[0];
    _ = slice;
}

// error
//
// :2:41: error: use of undefined value here causes illegal behavior