Skip to content

Commit 00ae2b7

Browse files
committed
removed range check for float extended reduce
1 parent 4d53359 commit 00ae2b7

File tree

1 file changed

+3
-6
lines changed

1 file changed

+3
-6
lines changed

src/util/float_extended.rs

Lines changed: 3 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -22,12 +22,9 @@ impl FloatExtended {
2222

2323
#[inline]
2424
pub fn reduce(&mut self) {
25-
// Check to make sure that the mantissa is outside of the new bounds
26-
if self.mantissa < 0.5 || self.mantissa > 1.0 {
27-
let (temp_mantissa, added_exponent) = self.mantissa.frexp();
28-
self.mantissa = temp_mantissa;
29-
self.exponent += added_exponent;
30-
}
25+
let (temp_mantissa, added_exponent) = self.mantissa.frexp();
26+
self.mantissa = temp_mantissa;
27+
self.exponent += added_exponent;
3128
}
3229

3330
#[inline]

0 commit comments

Comments
 (0)