pub trait SimdFrom<T, S: Simd> {
// Required method
fn simd_from(value: T, simd: S) -> Self;
}
Expand description
Value conversion, adding a SIMD blessing.
Analogous to From
, but takes a SIMD token, which is used to bless
the new value. Most such conversions are safe transmutes, but this
trait also supports splats, and implementations can use the SIMD token
to use an efficient splat intrinsic.
The SimdInto
trait is also provided for convenience.
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.