jayzhan211 commented on PR #10354:
URL: https://github.com/apache/datafusion/pull/10354#issuecomment-2099524811

   Another option is to introduce `has_simplify` so we can simplify the code to
   ```rust
               Expr::AggregateFunction(AggregateFunction {
                   func_def: AggregateFunctionDefinition::UDF(udaf),
                   args: AggregateFunctionArgs,
               }) if udaf.has_simplify() => {
                   Transformed::yes(udaf.simplify()?)
               }
   ```
   
   But the downside is that the user needs to both define `simplify` and set 
`has_simplify` to true.


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