Fix handling of uppercase characters in fuzzy finding
This commit is contained in:
@@ -1,3 +1,5 @@
|
||||
use std::iter::FromIterator;
|
||||
|
||||
#[derive(Copy, Clone, Debug, Default)]
|
||||
pub struct CharBag(u64);
|
||||
|
||||
@@ -31,6 +33,14 @@ impl Extend<char> for CharBag {
|
||||
}
|
||||
}
|
||||
|
||||
impl FromIterator<char> for CharBag {
|
||||
fn from_iter<T: IntoIterator<Item = char>>(iter: T) -> Self {
|
||||
let mut result = Self::default();
|
||||
result.extend(iter);
|
||||
result
|
||||
}
|
||||
}
|
||||
|
||||
impl From<&str> for CharBag {
|
||||
fn from(s: &str) -> Self {
|
||||
let mut bag = Self(0);
|
||||
|
||||
Reference in New Issue
Block a user