pub trait IntoInitPin<T: ?Sized, Marker = ()>: Sized {
type Init: InitPin<T, Error = Self::Error>;
type Error;
// Required method
fn into_init(self) -> Self::Init;
}Expand description
A trait for converting a value into a pin-initializer for type T.
This trait is used to allow types to be directly used as initializers without needing to wrap them in a specific initializer factory function.
There does not exist a trait called IntoInitializer, which seems to be a
natural extension for the Initializer, InitPin, and Init subtrait
chain. This is because Marker and the target type T cannot be separated
for correct type inference.
Required Associated Types§
Required Methods§
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.