Apply review feedback

This commit is contained in:
Thom Chiovoloni
2020-10-06 13:40:39 -07:00
parent 541369c38e
commit 8d3d616b13
2 changed files with 10 additions and 5 deletions

View File

@@ -295,8 +295,7 @@ macro_rules! impl_float_vector {
#[inline]
pub fn abs(self) -> Self {
let no_sign = <$bits_ty>::splat(!0 >> 1);
let abs = unsafe { crate::intrinsics::simd_and(self.to_bits(), no_sign) };
Self::from_bits(abs)
Self::from_bits(self.to_bits() & no_sign)
}
}
};