1 2 3 4 5 6
use std::pin::Pin; use std::future::Future; pub type PinBox<T> = Pin<Box<T>>; pub type PinBoxFuture<T> = PinBox<dyn Future<Output=T> + 'static>;