|
@@ -24,6 +24,10 @@ impl Dictionary {
|
|
|
// so we're still using a normal Vec, and perform deduplication at load time
|
|
|
let mut aux_set = HashSet::new();
|
|
|
lines
|
|
|
+ .map(|res| match res {
|
|
|
+ Ok(word) => Ok(line_to_word(word.as_str())),
|
|
|
+ _ => res,
|
|
|
+ })
|
|
|
.filter(|res| match res {
|
|
|
Ok(word) => aux_set.insert(word.clone()),
|
|
|
_ => false,
|