Skip to main content

AsInnerSlice

Trait AsInnerSlice 

Source
pub trait AsInnerSlice<T>
where T: Number,
{ const _SIZE_CHECK: (); const _ALIGN_CHECK: (); // Required method fn as_inner_slice(&self) -> &[T]; }
Expand description

Convert a slice of PcoVecValue to a slice of the underlying Number type.

§Safety

This trait uses unsafe pointer casting that relies on compile-time size/alignment checks. The const assertions ensure T and T::NumberType have identical layout.

Required Associated Constants§

Required Methods§

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.

Implementations on Foreign Types§

Source§

impl<T> AsInnerSlice<<T as Pco>::NumberType> for [T]
where T: PcoVecValue,

Implementors§