fork/rust

git clone https://git.julia.blue/fork/rust

borsAuto merge of #103046 - JanBeh:PR_clarify_cmp_terminology, r=workingjubilee3bcad65fbf6

master
837 B21 linesraw
1error[E0277]: `PhantomPinned` cannot be unpinned
2  --> $DIR/pin-needed-to-poll-2.rs:43:18
3   |
4LL |         Pin::new(&mut self.sleep).poll(cx)
5   |         -------- ^^^^^^^^^^^^^^^ within `Sleep`, the trait `Unpin` is not implemented for `PhantomPinned`
6   |         |
7   |         required by a bound introduced by this call
8   |
9   = note: consider using the `pin!` macro
10           consider using `Box::pin` if you need to access the pinned value outside of the current scope
11note: required because it appears within the type `Sleep`
12  --> $DIR/pin-needed-to-poll-2.rs:8:8
13   |
14LL | struct Sleep(std::marker::PhantomPinned);
15   |        ^^^^^
16note: required by a bound in `Pin::<P>::new`
17  --> $SRC_DIR/core/src/pin.rs:LL:COL
18
19error: aborting due to previous error
20
21For more information about this error, try `rustc --explain E0277`.