mirror of
https://github.com/rust-lang/rust-clippy
synced 2024-11-30 16:39:26 +00:00
small fix
This commit is contained in:
parent
6a695ffb3d
commit
b1abc81a60
1 changed files with 2 additions and 2 deletions
|
@ -229,8 +229,8 @@ impl<'a> DigitInfo<'a> {
|
||||||
None => String::new(),
|
None => String::new(),
|
||||||
};
|
};
|
||||||
format!("{}.{}{}", int_part_hint, frac_part_hint, suffix_hint)
|
format!("{}.{}{}", int_part_hint, frac_part_hint, suffix_hint)
|
||||||
} else if self.float && (self.digits.contains("E") || self.digits.contains("E")) {
|
} else if self.float && (self.digits.contains('E') || self.digits.contains('e')) {
|
||||||
let which_e = if self.digits.contains("E") { "E" } else { "e" };
|
let which_e = if self.digits.contains('E') { 'E' } else { 'e' };
|
||||||
let parts: Vec<&str> = self.digits.split(which_e).collect();
|
let parts: Vec<&str> = self.digits.split(which_e).collect();
|
||||||
let filtered_digits_vec_0 = parts[0].chars().filter(|&c| c != '_').rev().collect::<Vec<_>>();
|
let filtered_digits_vec_0 = parts[0].chars().filter(|&c| c != '_').rev().collect::<Vec<_>>();
|
||||||
let filtered_digits_vec_1 = parts[1].chars().filter(|&c| c != '_').rev().collect::<Vec<_>>();
|
let filtered_digits_vec_1 = parts[1].chars().filter(|&c| c != '_').rev().collect::<Vec<_>>();
|
||||||
|
|
Loading…
Reference in a new issue