Skip to content

Commit 7e3fd59

Browse files
committed
Improve formatting in macro
1 parent e08d569 commit 7e3fd59

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

library/core/src/fmt/num.rs

+3-3
Original file line numberDiff line numberDiff line change
@@ -317,10 +317,10 @@ macro_rules! impl_Exp {
317317
}
318318
(fmt_prec.saturating_sub(prec), prec.saturating_sub(fmt_prec))
319319
}
320-
None => (0,0)
320+
None => (0, 0)
321321
};
322322
for _ in 1..subtracted_precision {
323-
n/=10;
323+
n /= 10;
324324
exponent += 1;
325325
}
326326
if subtracted_precision != 0 {
@@ -392,7 +392,7 @@ macro_rules! impl_Exp {
392392
// SAFETY: In either case, `exp_buf` is written within bounds and `exp_ptr[..len]`
393393
// is contained within `exp_buf` since `len <= 3`.
394394
let exp_slice = unsafe {
395-
*exp_ptr.offset(0) = if upper {b'E'} else {b'e'};
395+
*exp_ptr.offset(0) = if upper { b'E' } else { b'e' };
396396
let len = if exponent < 10 {
397397
*exp_ptr.offset(1) = (exponent as u8) + b'0';
398398
2

0 commit comments

Comments
 (0)