Skip to main content

CubeIndex

Trait CubeIndex 

Source
pub trait CubeIndex<I: CubeType>: Index<I, Output: CubeType> + CubeType<ExpandType: IndexExpand<I::ExpandType, Output = <Self::Output as CubeType>::ExpandType>> {
    // Provided method
    fn __expand_index<'this>(
        scope: &Scope,
        this: &'this Self::ExpandType,
        index: I::ExpandType,
    ) -> &'this <Self::Output as CubeType>::ExpandType { ... }
}
Expand description

Trait bound that can be used to guarantee the expand also implements IndexExpand

Provided Methods§

Source

fn __expand_index<'this>( scope: &Scope, this: &'this Self::ExpandType, index: I::ExpandType, ) -> &'this <Self::Output as CubeType>::ExpandType

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementors§

Source§

impl<I: CubeType, T: Index<I> + CubeType + ?Sized> CubeIndex<I> for T
where T::Output: CubeType, T::ExpandType: IndexExpand<I::ExpandType, Output = <<T as Index<I>>::Output as CubeType>::ExpandType>,