style: Clippy

This commit is contained in:
Ed Page 2021-07-27 14:28:16 -05:00
parent b1c473c9c1
commit 6037eebfdc

View file

@ -20,13 +20,11 @@ fn generate<W: std::io::Write>(file: &mut W, dict: &[u8]) {
let mut typo = i.next().expect("typo").to_owned(); let mut typo = i.next().expect("typo").to_owned();
typo.make_ascii_lowercase(); typo.make_ascii_lowercase();
let typo = UniCase::new(typo); let typo = UniCase::new(typo);
rows.entry(typo) rows.entry(typo).or_insert_with(Vec::new).extend(i.map(|c| {
.or_insert_with(|| Vec::new()) let mut c = c.to_owned();
.extend(i.map(|c| { c.make_ascii_lowercase();
let mut c = c.to_owned(); c
c.make_ascii_lowercase(); }));
c
}));
}); });
let disallowed_typos = varcon_words(); let disallowed_typos = varcon_words();