Sign in
rust
/
rust-lang
/
rust
/
refs/heads/try
/
.
/
tests
/
ui
/
pattern
/
usefulness
/
issue-65413-constants-and-slices-exhaustiveness.rs
blob: ebe6ce0629e68b9c124bd8baa4361b93c9ae4fcc [
file
] [
log
] [
blame
]
//@ check-pass
#![
deny
(
unreachable_patterns
)]
const
C0
:
&
'
static
[
u8
]
=
b
"\x00"
;
fn
main
()
{
let
x
:
&[
u8
]
=
&[
0
];
match
x
{
&[]
=>
{}
&[
1.
.=
255
]
=>
{}
C0
=>
{}
&[
_
,
_
,
..]
=>
{}
}
}