aboutsummaryrefslogtreecommitdiff
path: root/test/cases/compile_errors/branch_on_undefined_value.zig
blob: a58a515a6e9f5e7ea3657b50f6e17799c3d95e2d (plain)
1
2
3
4
5
6
7
8
9
const x = if (undefined) true else false;

export fn entry() usize {
    return @sizeOf(@TypeOf(x));
}

// error
//
// :1:15: error: use of undefined value here causes illegal behavior