pub trait WithLabelledGeneric: LabelledGeneric {
// Required methods
fn hmap<U: LabelledGeneric, F>(self, f: F) -> U
where Self::Repr: HMappable<Poly<F>, Output = U::Repr>;
fn hzip<U: LabelledGeneric, TU: LabelledGeneric<Repr = <Self::Repr as HZippable<U::Repr>>::Zipped>>(
self,
other: U,
) -> TU
where Self::Repr: HZippable<U::Repr>;
fn map_to_list<F, U>(
self,
f: F,
) -> ConsList<U, <Self::Repr as MapToList<F, U>>::Output>
where Self::Repr: MapToList<F, U>;
fn for_each<F>(self, f: F)
where Self::Repr: ForEach<F>;
}Expand description
Convenience functions for the caller to map between similarly-shaped types implementing LabelledGeneric without having to explicitly call LabelledGeneric::from and LabelledGeneric::into
Required Methods§
fn hmap<U: LabelledGeneric, F>(self, f: F) -> U
fn hzip<U: LabelledGeneric, TU: LabelledGeneric<Repr = <Self::Repr as HZippable<U::Repr>>::Zipped>>( self, other: U, ) -> TU
fn map_to_list<F, U>( self, f: F, ) -> ConsList<U, <Self::Repr as MapToList<F, U>>::Output>
fn for_each<F>(self, f: F)
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.