Sign in
rust
/
rust
/
58f80da065eede67f1476ecd5f30006e62dcc2fe
/
.
/
tests
/
ui
/
pattern
/
match-array-against-slice.rs
blob: a396e2adab8224ca9b31d821c4696b0d6757390a [
file
]
//! Regression test for <https://github.com/rust-lang/rust/issues/23311>.
//! Test that we do not ICE when pattern matching an array against a slice.
//@ run-pass
fn
main
()
{
match
"foo"
.
as_bytes
()
{
b
"food"
=>
(),
&[
b
'f'
,
..]
=>
(),
_
=>
()
}
}