mirror of
https://github.com/meilisearch/meilisearch.git
synced 2025-09-26 23:06:27 +00:00
increase rust version from 1.85 to 1.89
This commit is contained in:
@ -354,15 +354,14 @@ fn maybe_add_to_results<'ctx, Q: RankingRuleQueryTrait>(
|
||||
logger.add_to_results(&candidates);
|
||||
valid_docids.extend_from_slice(&candidates);
|
||||
valid_scores
|
||||
.extend(std::iter::repeat(ranking_rule_scores.to_owned()).take(candidates.len()));
|
||||
.extend(std::iter::repeat_n(ranking_rule_scores.to_owned(), candidates.len()));
|
||||
}
|
||||
} else {
|
||||
// if we have passed the offset already, add some of the documents (up to the limit)
|
||||
let candidates = candidates.iter().take(length - valid_docids.len()).collect::<Vec<u32>>();
|
||||
logger.add_to_results(&candidates);
|
||||
valid_docids.extend_from_slice(&candidates);
|
||||
valid_scores
|
||||
.extend(std::iter::repeat(ranking_rule_scores.to_owned()).take(candidates.len()));
|
||||
valid_scores.extend(std::iter::repeat_n(ranking_rule_scores.to_owned(), candidates.len()));
|
||||
}
|
||||
|
||||
*cur_offset += candidates.len() as usize;
|
||||
|
@ -193,6 +193,7 @@ impl<G: RankingRuleGraphTrait> VisitorState<G> {
|
||||
visit: VisitFn<'_, G>,
|
||||
ctx: &mut VisitorContext<'_, G>,
|
||||
) -> Result<ControlFlow<(), bool>> {
|
||||
#[allow(clippy::manual_contains)] // there is no method contains on mapped interner
|
||||
if !ctx
|
||||
.all_costs_from_node
|
||||
.get(dest_node)
|
||||
@ -243,6 +244,8 @@ impl<G: RankingRuleGraphTrait> VisitorState<G> {
|
||||
|
||||
// Checking that from the destination node, there is at least
|
||||
// one cost that we can visit that corresponds to our remaining budget.
|
||||
|
||||
#[allow(clippy::manual_contains)] // there is no contains on MappedInterner
|
||||
if !ctx
|
||||
.all_costs_from_node
|
||||
.get(dest_node)
|
||||
|
@ -401,7 +401,7 @@ impl Iterator for SmallBitmapInternalIter<'_> {
|
||||
*cur &= *cur - 1;
|
||||
Some(idx + *base)
|
||||
} else if next.is_empty() {
|
||||
return None;
|
||||
None
|
||||
} else {
|
||||
*base += 64;
|
||||
*cur = next[0];
|
||||
|
@ -79,7 +79,7 @@ impl<'ctx, Query> Sort<'ctx, Query> {
|
||||
return Ok(false);
|
||||
};
|
||||
|
||||
Ok(!displayed_fields.iter().any(|&field| field == field_name))
|
||||
Ok(!displayed_fields.contains(&field_name))
|
||||
}
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user