@@ -19,7 +19,7 @@ fn a() {
1919 [ box ref _a, _, _] => {
2020 //~^ borrow of `vec[..]` occurs here
2121 vec[ 0 ] = box 4 ; //~ ERROR cannot assign
22- //~^ assignment to `vec[..]` occurs here
22+ //~^ assignment to borrowed `vec[..]` occurs here
2323 }
2424 }
2525}
@@ -31,7 +31,7 @@ fn b() {
3131 [ _b..] => {
3232 //~^ borrow of `vec[..]` occurs here
3333 vec[ 0 ] = box 4 ; //~ ERROR cannot assign
34- //~^ assignment to `vec[..]` occurs here
34+ //~^ assignment to borrowed `vec[..]` occurs here
3535 }
3636 }
3737}
@@ -41,8 +41,8 @@ fn c() {
4141 let vec: & mut [ Box < isize > ] = & mut vec;
4242 match vec {
4343 [ _a, //~ ERROR cannot move out
44- //~| move occurs here
45- //~| attempting to move value to here
44+ //~| cannot move out
45+ //~| to prevent move
4646 _b..] => {
4747 // Note: `_a` is *moved* here, but `b` is borrowing,
4848 // hence illegal.
@@ -53,38 +53,38 @@ fn c() {
5353 _ => { }
5454 }
5555 let a = vec[ 0 ] ; //~ ERROR cannot move out
56- //~^ NOTE attempting to move value to here
57- //~| can not move out of here
56+ //~^ NOTE to prevent move
57+ //~| cannot move out of here
5858}
5959
6060fn d ( ) {
6161 let mut vec = vec ! ( box 1 , box 2 , box 3 ) ;
6262 let vec: & mut [ Box < isize > ] = & mut vec;
6363 match vec {
6464 [ _a.., //~ ERROR cannot move out
65- //~^ move occurs here
66- _b] => { } //~ NOTE attempting to move value to here
65+ //~^ cannot move out
66+ _b] => { } //~ NOTE to prevent move
6767 _ => { }
6868 }
6969 let a = vec[ 0 ] ; //~ ERROR cannot move out
70- //~^ NOTE attempting to move value to here
71- //~| can not move out of here
70+ //~^ NOTE to prevent move
71+ //~| cannot move out of here
7272}
7373
7474fn e ( ) {
7575 let mut vec = vec ! ( box 1 , box 2 , box 3 ) ;
7676 let vec: & mut [ Box < isize > ] = & mut vec;
7777 match vec {
7878 [ _a, _b, _c] => { } //~ ERROR cannot move out
79- //~| move occurs here
80- //~| NOTE attempting to move value to here
79+ //~| cannot move out
80+ //~| NOTE to prevent move
8181 //~| NOTE and here
8282 //~| NOTE and here
8383 _ => { }
8484 }
8585 let a = vec[ 0 ] ; //~ ERROR cannot move out
86- //~^ NOTE attempting to move value to here
87- //~| can not move out of here
86+ //~^ NOTE to prevent move
87+ //~| cannot move out of here
8888}
8989
9090fn main ( ) { }
0 commit comments