mirror of
https://github.com/meilisearch/meilisearch.git
synced 2024-11-26 03:55:07 +08:00
feat: Do the sum of typos using usizes
This commit is contained in:
parent
32f8908d71
commit
966eda8ae5
@ -18,7 +18,7 @@ fn sum_matches_typos(matches: &[Match]) -> isize {
|
|||||||
// note that GroupBy will never return an empty group
|
// note that GroupBy will never return an empty group
|
||||||
// so we can do this assumption safely
|
// so we can do this assumption safely
|
||||||
for group in GroupBy::new(matches, match_query_index) {
|
for group in GroupBy::new(matches, match_query_index) {
|
||||||
sum_typos += unsafe { group.get_unchecked(0).distance } as isize;
|
sum_typos += unsafe { group.get_unchecked(0).distance as isize };
|
||||||
number_words += 1;
|
number_words += 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user