When I write
let x: Int
switch x {
default:
print("x")
}
I get this error: error: constant 'x' used before being initialized
When I write
let x: Never
print(x)
I get this error: error: constant 'x' used before being initialized
But when I write
let x: Never
switch x {
default:
print("x")
}
I don’t get an error, but running the program results in a crash.
Why is this?
1 Like
Also, I would like to express that I was delighted by the excellent crash interface.
1 Like
xwu
(Xiaodi Wu)
3
Sounds like a bug in the compiler! Can you file an issue to have it triaged?