ZhangHuiGui commented on code in PR #40396:
URL: https://github.com/apache/arrow/pull/40396#discussion_r1521656690
##########
cpp/src/arrow/compute/expression.cc:
##########
@@ -845,7 +845,8 @@ Result<Expression> FoldConstants(Expression expr) {
std::move(expr), [](Expression expr) { return expr; },
[](Expression expr, ...) -> Result<Expression> {
auto call = CallNotNull(expr);
- if (std::all_of(call->arguments.begin(), call->arguments.end(),
+ if (!call->arguments.empty() &&
Review Comment:
I have add the is_impure property. But seems override
`Function::is_impure()` is not convenient. Because the built-in functions are
all added by `HashAggregateFunction`,`ScalarAggregateFunction` and other basic
inherited classes.
So i have added an init opts, then we could set the is_impure property when
we add the specific function into kernel.
How about this method?
--
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]