Update crates/core_simd/src/vector.rs
Co-authored-by: Jubilee <46493976+workingjubilee@users.noreply.github.com>
This commit is contained in:
parent
00165ed5be
commit
cf653c7b93
@ -336,6 +336,11 @@ mod sealed {
|
||||
use sealed::Sealed;
|
||||
|
||||
/// Marker trait for types that may be used as SIMD vector elements.
|
||||
/// SAFETY: This trait, when implemented, asserts the compiler can monomorphize
|
||||
/// `#[repr(simd)]` structs with the marked type as an element.
|
||||
/// Strictly, it is valid to impl if the vector will not be miscompiled.
|
||||
/// Practically, it is user-unfriendly to impl it if the vector won't compile,
|
||||
/// even when no soundness guarantees are broken by allowing the user to try.
|
||||
pub unsafe trait SimdElement: Sealed + Copy {
|
||||
/// The mask element type corresponding to this element type.
|
||||
type Mask: MaskElement;
|
||||
|
Loading…
x
Reference in New Issue
Block a user