pub struct NullVec<T, const LEN: usize>(_);
Expand description

A zero sized struct that implements StaticVec. It will always panic when trying to access any data within it. You should generally never have to use this struct, it is only here to avoid performance loss in some cases where functions might expect an argument that ypu know will never be used.

use slas::prelude::*;

unsafe{ NullVec::<f32, 10>::new() };

Implementations

Trait Implementations

Formats the value using the given formatter. Read more

Return pointer to first element. Read more

Return mutable pointer to first element. Read more

Return a reference to self with the type of StaticVecUnion

Return a mutable reference to self with the type of StaticVecUnion. If you want to write to a StaticVec, this is the method that should be used. This method is re-implemented for StaticCowVecs, so it perserves cow behavior even when cows are borrowed as StaticVec’s. Read more

Return a cow vector containing a reference to self.

Indexing without bounds checking. Read more

Same as Self::get_unchecked but mutable. Read more

Copies self into a StaticVecUnion.

Returns a static slice spanning from index i to i+SLEN. Read more

Returns a mutable static slice spanning from index i to i+SLEN. Read more

Statically use B as a backend for self.

Example Read more

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more

Immutably borrows from an owned value. Read more

Mutably borrows from an owned value. Read more

Returns the argument unchanged.

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

The type returned in the event of a conversion error.

Performs the conversion.

The type returned in the event of a conversion error.

Performs the conversion.