andygrove commented on code in PR #2040:
URL: https://github.com/apache/datafusion-comet/pull/2040#discussion_r2248037877


##########
native/core/src/execution/planner.rs:
##########
@@ -1153,7 +1161,7 @@ impl PhysicalPlanner {
                 let child_copied = 
Self::wrap_in_copy_exec(Arc::clone(&child.native_plan));
 
                 let sort = Arc::new(
-                    SortExec::new(LexOrdering::new(exprs?), 
Arc::clone(&child_copied))
+                    SortExec::new(LexOrdering::new(exprs?).unwrap(), 
Arc::clone(&child_copied))

Review Comment:
   note for other reviews: the `unwrap()` here is on an `Option`. This seems 
safe because it would only be `None` if the vector of sort expressions were 
empty.



##########
native/core/src/execution/planner.rs:
##########
@@ -1153,7 +1161,7 @@ impl PhysicalPlanner {
                 let child_copied = 
Self::wrap_in_copy_exec(Arc::clone(&child.native_plan));
 
                 let sort = Arc::new(
-                    SortExec::new(LexOrdering::new(exprs?), 
Arc::clone(&child_copied))
+                    SortExec::new(LexOrdering::new(exprs?).unwrap(), 
Arc::clone(&child_copied))

Review Comment:
   note for other reviewers: the `unwrap()` here is on an `Option`. This seems 
safe because it would only be `None` if the vector of sort expressions were 
empty.



-- 
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