Skip to content

Commit 212da12

Browse files
csmoeashtneoi
authored andcommitted
update test
1 parent af5edc3 commit 212da12

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

src/test/ui/suggestions/issue-51244.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -10,5 +10,5 @@
1010

1111
fn main() {
1212
let ref my_ref @ _ = 0;
13-
*my_ref = 0;
13+
*my_ref = 0; //~ ERROR cannot assign to immutable borrowed content `*my_ref` [E0594]
1414
}

src/test/ui/suggestions/issue-51244.stderr

+2-2
Original file line numberDiff line numberDiff line change
@@ -2,8 +2,8 @@ error[E0594]: cannot assign to immutable borrowed content `*my_ref`
22
--> $DIR/issue-51244.rs:13:5
33
|
44
LL | let ref my_ref @ _ = 0;
5-
| --- consider changing this to `ref mut`
6-
LL | *my_ref = 0;
5+
| -------------- consider changing this to `ref mut my_ref @ _`
6+
LL | *my_ref = 0; //~ ERROR cannot assign to immutable borrowed content `*my_ref` [E0594]
77
| ^^^^^^^^^^^ cannot borrow as mutable
88

99
error: aborting due to previous error

0 commit comments

Comments
 (0)