From 248a5b64bbdc22262d7fe08552b21cedafbd2470 Mon Sep 17 00:00:00 2001 From: ChJR Date: Sun, 25 Oct 2020 16:02:23 +0900 Subject: [PATCH] Fix format to recommended by clippy --- vm/src/cformat.rs | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/vm/src/cformat.rs b/vm/src/cformat.rs index 60d14a0fd..ab9302165 100644 --- a/vm/src/cformat.rs +++ b/vm/src/cformat.rs @@ -247,11 +247,11 @@ impl CFormatSpec { let mut exponent = 0; loop { if fraction >= 10.0 { - fraction = fraction / 10.0; - exponent = exponent + 1; + fraction /= 10.0; + exponent += 1; } else if fraction < 1.0 && fraction > 0.0 { - fraction = fraction * 10.0; - exponent = exponent - 1; + fraction *= 10.0; + exponent -= 1; } else { break; }