Trait palette::ArrayExt

source ·
pub unsafe trait ArrayExt {
    type Item;

    const LENGTH: usize;
}
Expand description

Extension trait for fixed size arrays.

§Safety

  • Item must be the type of the array’s items (eg: T in [T; N]).
  • LENGTH must be the length of the array (eg: N in [T; N]).

Required Associated Types§

source

type Item

The type of the array’s items.

Required Associated Constants§

source

const LENGTH: usize

The number of items in the array.

Object Safety§

This trait is not object safe.

Implementations on Foreign Types§

source§

impl<T, const N: usize> ArrayExt for [T; N]

§

type Item = T

source§

const LENGTH: usize = N

Implementors§