rust/src/test/ui/issue-45157.stderr

16 lines
645 B
Plaintext
Raw Normal View History

2018-01-24 07:14:58 -06:00
error[E0502]: cannot borrow `u.z.c` as immutable because it is also borrowed as mutable
--> $DIR/issue-45157.rs:37:20
|
2018-02-24 17:59:34 -06:00
LL | let mref = &mut u.s.a;
2018-01-24 07:14:58 -06:00
| ---------- mutable borrow occurs here
...
2018-02-24 17:59:34 -06:00
LL | let nref = &u.z.c;
2018-01-24 07:14:58 -06:00
| ^^^^^^ immutable borrow occurs here
LL | //~^ ERROR cannot borrow `u.z.c` as immutable because it is also borrowed as mutable [E0502]
LL | println!("{} {}", mref, nref)
| ---- borrow later used here
2018-01-24 07:14:58 -06:00
error: aborting due to previous error
2018-01-24 07:14:58 -06:00
2018-02-26 02:56:00 -06:00
If you want more information on this error, try using "rustc --explain E0502"