aboutsummaryrefslogtreecommitdiff
path: root/test/cases/compile_errors/assign_unreachable.zig
blob: f3d218e465568a6cbf513fac15af240d5cbb2693 (plain)
1
2
3
4
5
6
7
8
9
10
11
export fn f() void {
    const a = return;
    _ = a;
}

// error
// backend=stage2
// target=native
//
// :2:5: error: unreachable code
// :2:15: note: control flow is diverted here