pub trait ArrayN<T, const N: usize>: Array<T> {
// Required methods
fn zip_with<U, V, F>(self, other: [U; N], f: F) -> [V; N]
where F: FnMut(T, U) -> V,
Self: Sized;
fn downcast(self) -> [T; N];
fn downcast_ref(&self) -> &[T; N];
fn downcast_mut(&mut self) -> &mut [T; N];
}Expand description
Array with size information on the type.
Required Methods§
Sourcefn zip_with<U, V, F>(self, other: [U; N], f: F) -> [V; N]
fn zip_with<U, V, F>(self, other: [U; N], f: F) -> [V; N]
Merges elements with another array by calling a FnMut(T, U) -> V closure for each pair.
Sourcefn downcast_ref(&self) -> &[T; N]
fn downcast_ref(&self) -> &[T; N]
Gets a reference to this object’s concrete array type.
Sourcefn downcast_mut(&mut self) -> &mut [T; N]
fn downcast_mut(&mut self) -> &mut [T; N]
Gets a mutable reference to this object’s concrete array type.