]> git.lizzy.rs Git - rust.git/blob - tests/ui/borrowck/borrowck-move-mut-base-ptr.stderr
Rollup merge of #106644 - alexcrichton:update-wasi-toolchain, r=cuviper
[rust.git] / tests / ui / borrowck / borrowck-move-mut-base-ptr.stderr
1 error[E0505]: cannot move out of `t0` because it is borrowed
2   --> $DIR/borrowck-move-mut-base-ptr.rs:10:14
3    |
4 LL |     let p: &isize = &*t0; // Freezes `*t0`
5    |                     ---- borrow of `*t0` occurs here
6 LL |     let t1 = t0;
7    |              ^^ move out of `t0` occurs here
8 LL |     *t1 = 22;
9 LL |     p.use_ref();
10    |     ----------- borrow later used here
11
12 error: aborting due to previous error
13
14 For more information about this error, try `rustc --explain E0505`.