mirror of
https://github.com/rust-lang/rust
synced 2024-11-05 20:45:15 +00:00
13 lines
310 B
Rust
13 lines
310 B
Rust
//@ compile-flags: --emit=link -Zmir-opt-level=2 -Zpolymorphize=on
|
|
|
|
fn foo<T>() {
|
|
let a: [i32; 0] = [];
|
|
match [a[..]] {
|
|
//~^ ERROR cannot move a value of type `[i32]
|
|
//~| ERROR cannot move out of type `[i32]`, a non-copy slice
|
|
[[x]] => {}
|
|
_ => (),
|
|
}
|
|
}
|
|
|
|
fn main() {}
|