Skip to content

Commit

Permalink
Satisfy clippy
Browse files Browse the repository at this point in the history
  • Loading branch information
mmarx committed Oct 23, 2023
1 parent 0ae02a6 commit 41676d9
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
2 changes: 1 addition & 1 deletion nemo-physical/src/tabular/table_types/trie.rs
Original file line number Diff line number Diff line change
Expand Up @@ -310,7 +310,7 @@ impl Table for Trie {
fn from_cols(cols: Vec<VecT>) -> Self {
debug_assert!({
// assert that columns have the same length
cols.get(0)
cols.first()
.map(|col| {
let len = col.len();
cols.iter().all(|col| col.len() == len)
Expand Down
8 changes: 4 additions & 4 deletions nemo/src/execution/planning/plan_body_seminaive.rs
Original file line number Diff line number Diff line change
Expand Up @@ -143,7 +143,7 @@ impl BodyStrategy for SeminaiveStrategy {
.get(
&aggregate
.variables
.get(0)
.first()
.expect("min aggregate requires exactly one variable")
.clone(),
)
Expand All @@ -165,9 +165,9 @@ impl BodyStrategy for SeminaiveStrategy {
// This is only required when the operation is not idempotent,
// because otherwise the the result would not change by intermediate columns in the variable order
if aggregated_column_index != aggregate_group_by_variables.len() {
panic!("aggregated variable {} is at an invalid position in the variable order to allow for aggregation without projection/reorder (index is {aggregated_column_index}, but should equal {}).", aggregate
.variables
.get(0).unwrap(), aggregate_group_by_variables.len());
panic!("aggregated variable {} is at an invalid position in the variable order to allow for aggregation without projection/reorder (index is {aggregated_column_index}, but should equal {}).",
aggregate.variables.first().unwrap(),
aggregate_group_by_variables.len());
}
}

Expand Down

0 comments on commit 41676d9

Please sign in to comment.