diff options
| author | Артём Павлов [Artyom Pavlov] <newpavlov@gmail.com> | 2022-05-27 05:15:22 +0300 |
|---|---|---|
| committer | Артём Павлов [Artyom Pavlov] <newpavlov@gmail.com> | 2022-05-27 05:15:22 +0300 |
| commit | 6495963d5a2d3e36ce799cfb932aa1a4b080f262 (patch) | |
| tree | 0d4f980d3c7e313ac95bd2933cfecab23f9716ca | |
| parent | 38609cd8a9113969746e6a0598fca7d13788e8ec (diff) | |
| download | rust-6495963d5a2d3e36ce799cfb932aa1a4b080f262.tar.gz rust-6495963d5a2d3e36ce799cfb932aa1a4b080f262.zip | |
fmt
| -rw-r--r-- | library/core/src/time.rs | 6 |
1 files changed, 1 insertions, 5 deletions
diff --git a/library/core/src/time.rs b/library/core/src/time.rs index 6983f10df3f..d653f715f6d 100644 --- a/library/core/src/time.rs +++ b/library/core/src/time.rs @@ -1291,11 +1291,7 @@ macro_rules! try_from_secs { // f32 does not have enough presicion to trigger the second branch // since it can not represent numbers between 0.999_999_940_395 and 1.0. let nanos = nanos + add_ns as u32; - if ($mant_bits == 23) || (nanos != NANOS_PER_SEC) { - (0, nanos) - } else { - (1, 0) - } + if ($mant_bits == 23) || (nanos != NANOS_PER_SEC) { (0, nanos) } else { (1, 0) } } else if exp < $mant_bits { let secs = u64::from(mant >> ($mant_bits - exp)); let t = <$double_ty>::from((mant << exp) & MANT_MASK); |
