findepi commented on code in PR #12177:
URL: https://github.com/apache/datafusion/pull/12177#discussion_r1734568985
##########
datafusion/optimizer/src/eliminate_duplicated_expr.rs:
##########
@@ -79,14 +51,15 @@ impl OptimizerRule for EliminateDuplicatedExpr {
match plan {
LogicalPlan::Sort(sort) => {
let len = sort.expr.len();
- let unique_exprs: Vec<_> = sort
- .expr
- .into_iter()
- .map(|e| SortExprWrapper { expr: e })
- .collect::<IndexSet<_>>()
- .into_iter()
- .map(|wrapper| wrapper.expr)
- .collect();
+ let mut first_sort_by_expr: IndexMap<Expr, SortExpr> =
+ IndexMap::default();
+ for s in &sort.expr {
Review Comment:
done!
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]