rust/tests/ui/pattern/usefulness/issue-66501.rs
2024-02-16 20:02:50 +00:00

13 lines
210 B
Rust

//@ check-pass
#![allow(unreachable_patterns)]
fn main() {
const CONST: &[Option<()>; 1] = &[Some(())];
match &[Some(())] {
&[None] => {}
CONST => {}
&[Some(())] => {}
}
}