]> git.proxmox.com Git - rustc.git/blob - src/test/ui/rfc-2005-default-binding-mode/explicit-mut.nll.stderr
New upstream version 1.27.1+dfsg1
[rustc.git] / src / test / ui / rfc-2005-default-binding-mode / explicit-mut.nll.stderr
1 error[E0594]: cannot assign to data in a `&` reference
2 --> $DIR/explicit-mut.rs:17:13
3 |
4 LL | Some(n) => {
5 | - help: consider changing this to be a mutable reference: `&mut`
6 LL | *n += 1; //~ ERROR cannot assign to immutable
7 | ^^^^^^^
8
9 error[E0594]: cannot assign to data in a `&` reference
10 --> $DIR/explicit-mut.rs:25:13
11 |
12 LL | Some(n) => {
13 | - help: consider changing this to be a mutable reference: `&mut`
14 LL | *n += 1; //~ ERROR cannot assign to immutable
15 | ^^^^^^^
16
17 error[E0594]: cannot assign to data in a `&` reference
18 --> $DIR/explicit-mut.rs:33:13
19 |
20 LL | Some(n) => {
21 | - help: consider changing this to be a mutable reference: `&mut`
22 LL | *n += 1; //~ ERROR cannot assign to immutable
23 | ^^^^^^^
24
25 error: aborting due to 3 previous errors
26
27 For more information about this error, try `rustc --explain E0594`.