erratic-pattern commented on code in PR #10358:
URL: https://github.com/apache/datafusion/pull/10358#discussion_r1588552841


##########
datafusion/optimizer/src/simplify_expressions/expr_simplifier.rs:
##########
@@ -450,6 +463,9 @@ impl<'a> TreeNodeRewriter for ConstEvaluator<'a> {
                     ConstSimplifyResult::Simplified(s) => {
                         Ok(Transformed::yes(Expr::Literal(s)))
                     }
+                    ConstSimplifyResult::NotSimplified(s) => {

Review Comment:
   I had to add a new variant to this result type so that the constant 
evaluator would return with `Transformed::no` when it encounters a `Literal`. 
It was always returning `Transformed::yes` and forcing the loop to go to the 
max iterations.



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

Reply via email to