]> git.lizzy.rs Git - rust.git/blob - src/test/ui/mut/mut-cross-borrowing.stderr
Rollup merge of #95376 - WaffleLapkin:drain_keep_rest, r=dtolnay
[rust.git] / src / test / ui / mut / mut-cross-borrowing.stderr
1 error[E0308]: mismatched types
2   --> $DIR/mut-cross-borrowing.rs:7:7
3    |
4 LL |     f(x)
5    |     - ^
6    |     | |
7    |     | expected `&mut isize`, found struct `Box`
8    |     | help: consider mutably borrowing here: `&mut x`
9    |     arguments to this function are incorrect
10    |
11    = note: expected mutable reference `&mut isize`
12                          found struct `Box<{integer}>`
13 note: function defined here
14   --> $DIR/mut-cross-borrowing.rs:1:4
15    |
16 LL | fn f(_: &mut isize) {}
17    |    ^ -------------
18
19 error: aborting due to previous error
20
21 For more information about this error, try `rustc --explain E0308`.