pub fn waker<W>(wake: Arc<W>) -> Waker
where
    W: ArcWake + 'static,
{
    let ptr = Arc::into_raw(wake).cast::<()>();

    unsafe { Waker::from_raw(RawWaker::new(ptr, waker_vtable::<W>())) }
}
Creates a [`Waker`] from an `Arc<impl ArcWake>`.

The returned [`Waker`] will call
[`ArcWake.wake()`](ArcWake::wake) if awoken.
futures-task/src/waker.rs