11use crate :: LanesAtMost32 ;
22
33macro_rules! implement_mask_ops {
4- { $( $vector: ident => $mask: ident ( $inner_mask_ty : ident , $ inner_ty: ident) , ) * } => {
4+ { $( $vector: ident => $mask: ident ( $inner_ty: ident) , ) * } => {
55 $(
66 impl <const LANES : usize > crate :: $vector<LANES >
77 where
@@ -12,53 +12,47 @@ macro_rules! implement_mask_ops {
1212 #[ inline]
1313 pub fn lanes_eq( self , other: Self ) -> crate :: $mask<LANES > {
1414 unsafe {
15- crate :: $inner_mask_ty:: from_int_unchecked( crate :: intrinsics:: simd_eq( self , other) )
16- . into( )
15+ crate :: $mask:: from_int_unchecked( crate :: intrinsics:: simd_eq( self , other) )
1716 }
1817 }
1918
2019 /// Test if each lane is not equal to the corresponding lane in `other`.
2120 #[ inline]
2221 pub fn lanes_ne( self , other: Self ) -> crate :: $mask<LANES > {
2322 unsafe {
24- crate :: $inner_mask_ty:: from_int_unchecked( crate :: intrinsics:: simd_ne( self , other) )
25- . into( )
23+ crate :: $mask:: from_int_unchecked( crate :: intrinsics:: simd_ne( self , other) )
2624 }
2725 }
2826
2927 /// Test if each lane is less than the corresponding lane in `other`.
3028 #[ inline]
3129 pub fn lanes_lt( self , other: Self ) -> crate :: $mask<LANES > {
3230 unsafe {
33- crate :: $inner_mask_ty:: from_int_unchecked( crate :: intrinsics:: simd_lt( self , other) )
34- . into( )
31+ crate :: $mask:: from_int_unchecked( crate :: intrinsics:: simd_lt( self , other) )
3532 }
3633 }
3734
3835 /// Test if each lane is greater than the corresponding lane in `other`.
3936 #[ inline]
4037 pub fn lanes_gt( self , other: Self ) -> crate :: $mask<LANES > {
4138 unsafe {
42- crate :: $inner_mask_ty:: from_int_unchecked( crate :: intrinsics:: simd_gt( self , other) )
43- . into( )
39+ crate :: $mask:: from_int_unchecked( crate :: intrinsics:: simd_gt( self , other) )
4440 }
4541 }
4642
4743 /// Test if each lane is less than or equal to the corresponding lane in `other`.
4844 #[ inline]
4945 pub fn lanes_le( self , other: Self ) -> crate :: $mask<LANES > {
5046 unsafe {
51- crate :: $inner_mask_ty:: from_int_unchecked( crate :: intrinsics:: simd_le( self , other) )
52- . into( )
47+ crate :: $mask:: from_int_unchecked( crate :: intrinsics:: simd_le( self , other) )
5348 }
5449 }
5550
5651 /// Test if each lane is greater than or equal to the corresponding lane in `other`.
5752 #[ inline]
5853 pub fn lanes_ge( self , other: Self ) -> crate :: $mask<LANES > {
5954 unsafe {
60- crate :: $inner_mask_ty:: from_int_unchecked( crate :: intrinsics:: simd_ge( self , other) )
61- . into( )
55+ crate :: $mask:: from_int_unchecked( crate :: intrinsics:: simd_ge( self , other) )
6256 }
6357 }
6458 }
@@ -67,18 +61,18 @@ macro_rules! implement_mask_ops {
6761}
6862
6963implement_mask_ops ! {
70- SimdI8 => Mask8 ( SimdMask8 , SimdI8 ) ,
71- SimdI16 => Mask16 ( SimdMask16 , SimdI16 ) ,
72- SimdI32 => Mask32 ( SimdMask32 , SimdI32 ) ,
73- SimdI64 => Mask64 ( SimdMask64 , SimdI64 ) ,
74- SimdIsize => MaskSize ( SimdMaskSize , SimdIsize ) ,
64+ SimdI8 => Mask8 ( SimdI8 ) ,
65+ SimdI16 => Mask16 ( SimdI16 ) ,
66+ SimdI32 => Mask32 ( SimdI32 ) ,
67+ SimdI64 => Mask64 ( SimdI64 ) ,
68+ SimdIsize => MaskSize ( SimdIsize ) ,
7569
76- SimdU8 => Mask8 ( SimdMask8 , SimdI8 ) ,
77- SimdU16 => Mask16 ( SimdMask16 , SimdI16 ) ,
78- SimdU32 => Mask32 ( SimdMask32 , SimdI32 ) ,
79- SimdU64 => Mask64 ( SimdMask64 , SimdI64 ) ,
80- SimdUsize => MaskSize ( SimdMaskSize , SimdIsize ) ,
70+ SimdU8 => Mask8 ( SimdI8 ) ,
71+ SimdU16 => Mask16 ( SimdI16 ) ,
72+ SimdU32 => Mask32 ( SimdI32 ) ,
73+ SimdU64 => Mask64 ( SimdI64 ) ,
74+ SimdUsize => MaskSize ( SimdIsize ) ,
8175
82- SimdF32 => Mask32 ( SimdMask32 , SimdI32 ) ,
83- SimdF64 => Mask64 ( SimdMask64 , SimdI64 ) ,
76+ SimdF32 => Mask32 ( SimdI32 ) ,
77+ SimdF64 => Mask64 ( SimdI64 ) ,
8478}
0 commit comments