提交 212da122 编写于 作者: C csmoe 提交者: ashtneoi

update test

上级 af5edc32
......@@ -10,5 +10,5 @@
fn main() {
let ref my_ref @ _ = 0;
*my_ref = 0;
*my_ref = 0; //~ ERROR cannot assign to immutable borrowed content `*my_ref` [E0594]
}
......@@ -2,8 +2,8 @@ error[E0594]: cannot assign to immutable borrowed content `*my_ref`
--> $DIR/issue-51244.rs:13:5
|
LL | let ref my_ref @ _ = 0;
| --- consider changing this to `ref mut`
LL | *my_ref = 0;
| -------------- consider changing this to `ref mut my_ref @ _`
LL | *my_ref = 0; //~ ERROR cannot assign to immutable borrowed content `*my_ref` [E0594]
| ^^^^^^^^^^^ cannot borrow as mutable
error: aborting due to previous error
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册