Incorrect "reaches end of non-void function" error when `catch` clause calls a never-returning function
awesomekling opened this issue · comments
Andreas Kling commented
This currently fails to compile, despite being valid. abort()
has return type never
in the prelude, so the compiler should see that all branches return here.
fn foo() -> [i64] {
try {
return []
} catch {
abort()
}
}