1 error[E0507]: cannot move out of dereference of raw pointer
2 --> $DIR/borrowck-move-from-unsafe-ptr.rs:13:13
4 LL | let y = *x; //~ ERROR cannot move out of dereference of raw pointer
7 | cannot move out of dereference of raw pointer
8 | help: consider removing the `*`: `x`
10 error[E0507]: cannot move out of `*x` which is behind a `*const` pointer
11 --> $DIR/borrowck-move-from-unsafe-ptr.rs:13:13
13 LL | unsafe fn foo(x: *const Box<isize>) -> Box<isize> {
14 | ----------------- help: consider changing this to be a mutable pointer: `*mut std::boxed::Box<isize>`
15 LL | let y = *x; //~ ERROR cannot move out of dereference of raw pointer
18 | cannot move out of `*x` which is behind a `*const` pointer
19 | `x` is a `*const` pointer, so the data it refers to cannot be moved
21 error: aborting due to 2 previous errors
23 For more information about this error, try `rustc --explain E0507`.