Unreliable warnings about unreachable code downstream of uninhabited expression #107179
Labels
A-diagnostics
Area: Messages for errors, warnings, and lints
T-compiler
Relevant to the compiler team, which will review and decide on the PR/issue.
Code
Current output
Rationale and extra context
It should warn on the first (and every) unreachable expression, not just the seemingly random set of expressions it fires on here. Note that if you change any of the
make_infallible()
calls topanic!()
it will warn at the correct spots. So I think this is specifically related to the treatment of empty types.The text was updated successfully, but these errors were encountered: