Reenable ops and fix tests

This commit is contained in:
Caleb Zulawski
2020-12-06 00:36:33 -05:00
parent 22576bb6e0
commit 25c7640fb3
6 changed files with 112 additions and 204 deletions

View File

@@ -295,13 +295,13 @@ macro_rules! impl_float_vector {
unsafe { core::mem::transmute_copy(&bits) }
}
// /// Produces a vector where every lane has the absolute value of the
// /// equivalently-indexed lane in `self`.
// #[inline]
// pub fn abs(self) -> Self {
// let no_sign = <$bits_ty>::splat(!0 >> 1);
// Self::from_bits(self.to_bits() & no_sign)
// }
/// Produces a vector where every lane has the absolute value of the
/// equivalently-indexed lane in `self`.
#[inline]
pub fn abs(self) -> Self {
let no_sign = crate::$bits_ty::splat(!0 >> 1);
Self::from_bits(self.to_bits() & no_sign)
}
}
};
}