mirror of
https://github.com/meilisearch/meilisearch.git
synced 2024-11-30 09:04:59 +08:00
Skip looking at connections for proximity 0
This commit is contained in:
parent
c84012d655
commit
beb49b24f6
@ -126,6 +126,7 @@ impl Index {
|
|||||||
let mut runion_docids = RoaringBitmap::default();
|
let mut runion_docids = RoaringBitmap::default();
|
||||||
let contains_documents = |(lword, lpos): (usize, u32), (rword, rpos): (usize, u32)| {
|
let contains_documents = |(lword, lpos): (usize, u32), (rword, rpos): (usize, u32)| {
|
||||||
let proximity = best_proximity::positions_proximity(lpos, rpos);
|
let proximity = best_proximity::positions_proximity(lpos, rpos);
|
||||||
|
if proximity == 0 { return false }
|
||||||
|
|
||||||
*intersect_cache.entry(((lword, lpos), (rword, rpos))).or_insert_with(|| {
|
*intersect_cache.entry(((lword, lpos), (rword, rpos))).or_insert_with(|| {
|
||||||
// let (nb_words, nb_docs_intersect, lnblookups, lnbbitmaps, rnblookups, rnbbitmaps) =
|
// let (nb_words, nb_docs_intersect, lnblookups, lnbbitmaps, rnblookups, rnbbitmaps) =
|
||||||
|
Loading…
Reference in New Issue
Block a user