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