taiki-e / pin-project-lite

A lightweight version of pin-project written with declarative macros.
https://docs.rs/pin-project-lite
Apache License 2.0
226 stars 16 forks source link

Add support for `#[project(!Unpin)]` #76

Closed matheus-consoli closed 1 year ago

matheus-consoli commented 1 year ago

This PR adds support to making types !Unpin.

Ex.:

pin_project! {
    #[project(!Unpin)]
    struct Foo<A, B> {
       #[pin]
       a: A,
       b: B,
    }
}

We also hide the documentation of the implementation that makes the type !Unpin, so it should not show in the rustdoc sidebar.

closes: #75

taiki-e commented 1 year ago

Published in 0.2.11.