New version of clippy has a lot of new lints

Lots of new clippy lints due to toolchain upgrade.

Made the Message::error field pub(crate) again, it was the odd one out
and it seemed a reasonable way to shut up clippy.
This commit is contained in:
Floris Bruynooghe
2021-01-18 22:57:41 +01:00
parent 2435803fa3
commit 83dd1c6232
10 changed files with 98 additions and 86 deletions

View File

@@ -407,7 +407,7 @@ impl std::str::FromStr for Fingerprint {
let hex_repr: String = input
.to_uppercase()
.chars()
.filter(|&c| c >= '0' && c <= '9' || c >= 'A' && c <= 'F')
.filter(|&c| ('0'..='9').contains(&c) || ('A'..='F').contains(&c))
.collect();
let v: Vec<u8> = hex::decode(hex_repr)?;
let fp = Fingerprint::new(v)?;