From c38bbfe11c3459a6ea3f832b04592a95c329de61 Mon Sep 17 00:00:00 2001 From: YakoYakoYokuYoku <39890836+YakoYakoYokuYoku@users.noreply.github.com> Date: Sat, 9 Feb 2019 16:56:37 -0300 Subject: [PATCH] Update float.rs --- src/float.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/float.rs b/src/float.rs index 275f85e..3ba0edd 100644 --- a/src/float.rs +++ b/src/float.rs @@ -1802,7 +1802,7 @@ pub trait Float: Num + Copy + NumCast + PartialOrd + Neg { /// assert!(n.imag() == 0.0f64); /// ``` fn imag(self) -> Self { - Self::zero() + self * Self::zero() } /// Returns the mantissa, base 2 exponent, and sign as integers, respectively.