Fix clippy warnings (#3165)

* Fix clippy warnings
This commit is contained in:
Paul Masurel
2026-10-08 18:23:57 +02:00
committed by GitHub
parent c091be8597
commit fc5770124e
3 changed files with 9 additions and 5 deletions
@@ -759,9 +759,11 @@ pub(crate) fn build_segment_histogram_collector(
children: Vec<AggNode>,
) -> crate::Result<Box<dyn SegmentAggregationCollector>> {
// Computed sources may change cardinality between blocks.
let source_contains_multivalues = req_data.accessor.as_column().map_or(true, |column| {
let source_contains_multivalues = if let Some(column) = req_data.accessor.as_column() {
column.index.get_cardinality().is_multivalue()
});
} else {
true
};
if source_contains_multivalues {
build_histogram_collector_with_cardinality::<true>(agg_data, req_data, children)
} else {
+4 -2
View File
@@ -353,9 +353,11 @@ pub(crate) fn build_segment_range_collector(
children: Vec<AggNode>,
) -> crate::Result<Box<dyn SegmentAggregationCollector>> {
// Computed sources may change cardinality between blocks.
let source_contains_multivalues = req_data.accessor.as_column().map_or(true, |column| {
let source_contains_multivalues = if let Some(column) = req_data.accessor.as_column() {
column.index.get_cardinality().is_multivalue()
});
} else {
true
};
if source_contains_multivalues {
build_range_collector_with_cardinality::<true>(agg_data, req_data, children)
} else {
+1 -1
View File
@@ -361,7 +361,7 @@ where
// we could check always_match_at == Some(0), but this actually gets
// inlined into `true` with AlwaysMatch, which is even faster
self.automaton
.will_always_match(&self.states.first().unwrap()),
.will_always_match(self.states.first().unwrap()),
self.upper_bound == Bound::Unbounded,
) {
(true, true) => self.advance_always_match::<true>(),