14 lines
277 B
Rust
14 lines
277 B
Rust
#![feature(slice_patterns)]
|
|
|
|
fn check(list: &[Option<()>]) {
|
|
match list {
|
|
//~^ ERROR `&[_, Some(_), None, _]` not covered
|
|
&[] => {},
|
|
&[_] => {},
|
|
&[_, _] => {},
|
|
&[_, None, ..] => {},
|
|
&[.., Some(_), _] => {},
|
|
}
|
|
}
|
|
|
|
fn main() {}
|