Re: [PATCH v2 3/3] rust: workqueue: add `#[pin_data]` to `Work`

From: Alice Ryhl
Date: Thu Jan 04 2024 - 10:19:34 EST


On Wed, Dec 13, 2023 at 11:09 PM Benno Lossin <benno.lossin@xxxxxxxxx> wrote:
>
> The previous two patches made it possible to add `#[pin_data]` on
> structs with default generic parameter values.
> This patch makes `Work` use `#[pin_data]` and removes an invocation of
> `pin_init_from_closure`. This function is intended as a low level manual
> escape hatch, so it is better to rely on the safe `pin_init!` macro.
>
> Signed-off-by: Benno Lossin <benno.lossin@xxxxxxxxx>

Tested-by: Alice Ryhl <aliceryhl@xxxxxxxxxx>
Reviewed-by: Alice Ryhl <aliceryhl@xxxxxxxxxx>