Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion datafusion/expr/src/utils.rs
Original file line number Diff line number Diff line change
Expand Up @@ -569,7 +569,7 @@ pub fn compare_sort_expr(
}
Ordering::Equal
}
_ => Ordering::Equal,
_ => panic!("Sort expressions must be of type Sort"),
}
}

Expand Down
4 changes: 3 additions & 1 deletion datafusion/sql/src/expr/function.rs
Original file line number Diff line number Diff line change
Expand Up @@ -295,8 +295,10 @@ impl<'a, S: ContextProvider> SqlToRel<'a, S> {
Some(false)
};
}
Some(false)
} else {
panic!("order_by expression must be of type Sort");
}
Some(false)
});

let window_frame = window
Expand Down
2 changes: 2 additions & 0 deletions datafusion/sql/src/unparser/rewrite.rs
Original file line number Diff line number Diff line change
Expand Up @@ -164,6 +164,8 @@ pub(super) fn rewrite_plan_for_sort_on_non_projected_fields(
for expr in &sort.expr {
if let Expr::Sort(s) = expr {
collects.push(s.expr.as_ref().clone());
} else {
panic!("sort expression must be of type Sort");
}
}

Expand Down