diff options
Diffstat (limited to 'tests/ui/moves/move-out-of-slice-2.rs')
| -rw-r--r-- | tests/ui/moves/move-out-of-slice-2.rs | 14 |
1 files changed, 4 insertions, 10 deletions
diff --git a/tests/ui/moves/move-out-of-slice-2.rs b/tests/ui/moves/move-out-of-slice-2.rs index 2f7394fbfd3..6428dc4b711 100644 --- a/tests/ui/moves/move-out-of-slice-2.rs +++ b/tests/ui/moves/move-out-of-slice-2.rs @@ -1,5 +1,3 @@ -#![feature(unsized_locals)] -//~^ WARN the feature `unsized_locals` is incomplete #![allow(unused)] struct A; @@ -9,28 +7,24 @@ struct C; fn main() { let a: Box<[A]> = Box::new([A]); match *a { - //~^ ERROR cannot move out of type `[A]`, a non-copy slice - [a @ ..] => {} + [a @ ..] => {} //~ERROR the size for values of type `[A]` cannot be known at compilation time [E0277] _ => {} } let b: Box<[A]> = Box::new([A, A, A]); match *b { - //~^ ERROR cannot move out of type `[A]`, a non-copy slice - [_, _, b @ .., _] => {} + [_, _, b @ .., _] => {} //~ERROR the size for values of type `[A]` cannot be known at compilation time [E0277] _ => {} } // `[C]` isn't `Copy`, even if `C` is. let c: Box<[C]> = Box::new([C]); match *c { - //~^ ERROR cannot move out of type `[C]`, a non-copy slice - [c @ ..] => {} + [c @ ..] => {} //~ERROR the size for values of type `[C]` cannot be known at compilation time [E0277] _ => {} } let d: Box<[C]> = Box::new([C, C, C]); match *d { - //~^ ERROR cannot move out of type `[C]`, a non-copy slice - [_, _, d @ .., _] => {} + [_, _, d @ .., _] => {} //~ERROR the size for values of type `[C]` cannot be known at compilation time [E0277] _ => {} } } |
