pub trait List<T: CubeType>: CubeType<ExpandType: ListExpand<T>> {
// Provided methods
fn read(&self, index: u32) -> T { ... }
fn read_unchecked(&self, index: u32) -> T { ... }
fn __expand_read(
scope: &mut Scope,
this: Self::ExpandType,
index: ExpandElementTyped<u32>,
) -> T::ExpandType { ... }
fn __expand_read_unchecked(
scope: &mut Scope,
this: Self::ExpandType,
index: ExpandElementTyped<u32>,
) -> T::ExpandType { ... }
}
Expand description
Type from which we can read values in cube functions. For a mutable version, see ListMut.
Provided Methods§
fn read(&self, index: u32) -> T
fn read_unchecked(&self, index: u32) -> T
fn __expand_read( scope: &mut Scope, this: Self::ExpandType, index: ExpandElementTyped<u32>, ) -> T::ExpandType
fn __expand_read_unchecked( scope: &mut Scope, this: Self::ExpandType, index: ExpandElementTyped<u32>, ) -> T::ExpandType
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.