You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository was archived by the owner on May 28, 2025. It is now read-only.
Rollup merge of rust-lang#89870 - tmandry:box-pin, r=estebank
Suggest Box::pin when Pin::new is used instead
This fixes an incorrect diagnostic.
**Based on rust-lang#89390**; only the last commit is specific to this PR. "Ignore whitespace changes" also helps here.
= note: for more on the distinction between the stack and the heap, read https://doc.rust-lang.org/book/ch15-01-box.html, https://doc.rust-lang.org/rust-by-example/std/box.html, and https://doc.rust-lang.org/std/boxed/index.html
40
-
help: store this in the heap by calling `Box::new`
41
-
|
42
-
LL | Pin::new(Box::new(x))
43
-
| +++++++++ +
44
41
45
42
error[E0277]: `dyn Future<Output = i32> + Send` cannot be unpinned
0 commit comments