diff --git a/Cargo.toml b/Cargo.toml index 28d6236..414b321 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -11,7 +11,7 @@ license = "MIT OR Apache-2.0" readme = "README.md" [dependencies.doubled] -version = "0.3.1" +version = "0.3.2" features = ["simd"] [features] diff --git a/src/f32x.rs b/src/f32x.rs index 39989c5..8203b66 100644 --- a/src/f32x.rs +++ b/src/f32x.rs @@ -51,9 +51,7 @@ pub use u35::{ use crate::common::*; use doubled::*; -use core::simd::{ - LaneCount, Mask, Simd, SupportedLaneCount, -}; +use core::simd::{LaneCount, Mask, Simd, SupportedLaneCount}; type F32x = Simd; type U32x = Simd; diff --git a/src/f64.rs b/src/f64.rs index 2eb7535..72c767e 100644 --- a/src/f64.rs +++ b/src/f64.rs @@ -716,12 +716,8 @@ pub fn ldexp(x: f64, mut exp: i32) -> f64 { /// Integer exponent of an FP number pub fn ilogb(d: f64) -> i32 { let mut e = ilogbk(fabsk(d)); - e = if d == 0. { SLEEF_FP_ILOGB0 as i32 } else { e }; - e = if d.is_nan() { - SLEEF_FP_ILOGBNAN as i32 - } else { - e - }; + e = if d == 0. { SLEEF_FP_ILOGB0 } else { e }; + e = if d.is_nan() { SLEEF_FP_ILOGBNAN } else { e }; if d.is_infinite() { i32::MAX } else { diff --git a/src/f64/u10.rs b/src/f64/u10.rs index 9e6e4f6..39cdc1f 100644 --- a/src/f64/u10.rs +++ b/src/f64/u10.rs @@ -147,7 +147,7 @@ pub fn cos(d: f64) -> f64 { let u = t.mul_as_f(x); - if ((ql as isize) & 2) == 0 { + if (ql & 2) == 0 { -u } else { u diff --git a/src/f64x.rs b/src/f64x.rs index 768cab1..1cabd8b 100644 --- a/src/f64x.rs +++ b/src/f64x.rs @@ -43,9 +43,7 @@ pub use u35::{ }; use crate::common::*; -use core::simd::{ - LaneCount, Mask, Simd, SupportedLaneCount, -}; +use core::simd::{LaneCount, Mask, Simd, SupportedLaneCount}; use doubled::*; type F64x = Simd;