alamb commented on code in PR #17442:
URL: https://github.com/apache/datafusion/pull/17442#discussion_r2330795717


##########
datafusion/physical-expr-common/src/sort_expr.rs:
##########
@@ -367,8 +367,21 @@ impl LexOrdering {
     /// Creates a new [`LexOrdering`] from the given vector of sort 
expressions.
     /// If the vector is empty, returns `None`.
     pub fn new(exprs: impl IntoIterator<Item = PhysicalSortExpr>) -> 
Option<Self> {
-        let (non_empty, ordering) = Self::construct(exprs);
-        non_empty.then_some(ordering)
+        let exprs = exprs.into_iter();

Review Comment:
   > Code maintainability >> micro optimizations that potentially don't matter 
in grand scheme of things.
   
   I agree as long as the changes don't make the code noticably slower.



-- 
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: github-unsubscr...@datafusion.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: github-unsubscr...@datafusion.apache.org
For additional commands, e-mail: github-h...@datafusion.apache.org

Reply via email to