]> git.lizzy.rs Git - rust.git/blob - tests/ui/augmented-assignments.stderr
Rollup merge of #107091 - clubby789:infer-ftl-missing-dollar, r=compiler-errors
[rust.git] / tests / ui / augmented-assignments.stderr
1 error[E0505]: cannot move out of `x` because it is borrowed
2   --> $DIR/augmented-assignments.rs:16:5
3    |
4 LL |     x
5    |     - borrow of `x` occurs here
6 ...
7 LL |     x;
8    |     ^ move out of `x` occurs here
9
10 error[E0596]: cannot borrow `y` as mutable, as it is not declared as mutable
11   --> $DIR/augmented-assignments.rs:23:5
12    |
13 LL |     y
14    |     ^ cannot borrow as mutable
15    |
16 help: consider changing this to be mutable
17    |
18 LL |     let mut y = Int(2);
19    |         +++
20
21 error: aborting due to 2 previous errors
22
23 Some errors have detailed explanations: E0505, E0596.
24 For more information about an error, try `rustc --explain E0505`.