once_cell
once_cell copied to clipboard
unreachable patterns on 1.82 beta
> cargo +beta clippy
warning: unreachable pattern
--> src/lib.rs:593:17
|
593 | Err(void) => match void {},
| ^^^^^^^^^ matches no values because `unsync::OnceCell<T>::get_or_init::Void` is uninhabited
|
= note: to learn more about uninhabited types, see https://doc.rust-lang.org/nomicon/exotic-sizes.html#empty-types
= note: `#[warn(unreachable_patterns)]` on by default
(four more times)
Might be a compiler bug https://github.com/rust-lang/rust/issues/129352
possible workaround is to do export RUSTFLAGS", "-A unreachable_patterns"
That was a bug in rustc, it shouldn't be adding new unactionable warnings in the middle of an edition.