diff options
| author | Caleb Zulawski <caleb.zulawski@gmail.com> | 2022-03-15 00:17:14 +0000 |
|---|---|---|
| committer | Caleb Zulawski <caleb.zulawski@gmail.com> | 2022-03-15 00:17:14 +0000 |
| commit | 60486e08ed58698c7b6c2b5cd62a9fbd9080bc2f (patch) | |
| tree | 6a7eaf87c6975f8996300c6dc8a08d091e389d50 | |
| parent | 2a02c4d9cbee120915535f6fc8379849e10e8373 (diff) | |
| download | rust-60486e08ed58698c7b6c2b5cd62a9fbd9080bc2f.tar.gz rust-60486e08ed58698c7b6c2b5cd62a9fbd9080bc2f.zip | |
SimdPartialOrd implies SimdPartialEq
| -rw-r--r-- | crates/core_simd/src/ord.rs | 13 |
1 files changed, 2 insertions, 11 deletions
diff --git a/crates/core_simd/src/ord.rs b/crates/core_simd/src/ord.rs index befa4594595..9a87bc2e344 100644 --- a/crates/core_simd/src/ord.rs +++ b/crates/core_simd/src/ord.rs @@ -1,10 +1,7 @@ -use crate::simd::{intrinsics, LaneCount, Mask, Simd, SimdElement, SupportedLaneCount}; +use crate::simd::{intrinsics, LaneCount, Mask, Simd, SimdPartialEq, SupportedLaneCount}; /// Parallel `PartialOrd`. -pub trait SimdPartialOrd { - /// The mask type returned by each comparison. - type Mask; - +pub trait SimdPartialOrd: SimdPartialEq { /// Test if each lane is less than the corresponding lane in `other`. #[must_use = "method returns a new mask and does not mutate the original value"] fn simd_lt(self, other: Self) -> Self::Mask; @@ -51,8 +48,6 @@ macro_rules! impl_integer { where LaneCount<LANES>: SupportedLaneCount, { - type Mask = Mask<<$integer as SimdElement>::Mask, LANES>; - #[inline] fn simd_lt(self, other: Self) -> Self::Mask { // Safety: `self` is a vector, and the result of the comparison @@ -118,8 +113,6 @@ macro_rules! impl_float { where LaneCount<LANES>: SupportedLaneCount, { - type Mask = Mask<<$float as SimdElement>::Mask, LANES>; - #[inline] fn simd_lt(self, other: Self) -> Self::Mask { // Safety: `self` is a vector, and the result of the comparison @@ -161,8 +154,6 @@ macro_rules! impl_mask { where LaneCount<LANES>: SupportedLaneCount, { - type Mask = Self; - #[inline] fn simd_lt(self, other: Self) -> Self::Mask { // Safety: `self` is a vector, and the result of the comparison |
