2018-07-15 14:11:54 -07:00
|
|
|
error[E0506]: cannot assign to `*refr` because it is borrowed
|
2018-12-25 08:56:47 -07:00
|
|
|
--> $DIR/issue-40288.rs:16:5
|
2018-07-15 14:11:54 -07:00
|
|
|
|
|
|
|
|
LL | save_ref(&*refr, &mut out);
|
2019-04-22 08:40:08 +01:00
|
|
|
| ------ borrow of `*refr` occurs here
|
2018-07-15 14:11:54 -07:00
|
|
|
...
|
2019-03-09 15:03:44 +03:00
|
|
|
LL | *refr = 3;
|
2018-07-15 14:11:54 -07:00
|
|
|
| ^^^^^^^^^ assignment to borrowed `*refr` occurs here
|
2019-04-22 08:40:08 +01:00
|
|
|
...
|
|
|
|
LL | println!("{:?}", out[0]);
|
|
|
|
| ------ borrow later used here
|
2018-07-15 14:11:54 -07:00
|
|
|
|
|
|
|
error: aborting due to previous error
|
|
|
|
|
|
|
|
For more information about this error, try `rustc --explain E0506`.
|