924060929 commented on code in PR #14380: URL: https://github.com/apache/doris/pull/14380#discussion_r1026281332
########## fe/fe-core/src/main/java/org/apache/doris/catalog/AggregateFunction.java: ########## @@ -183,6 +183,30 @@ public AggregateFunction(FunctionName fnName, List<Type> argTypes, returnsNonNullOnEmpty = false; } + public AggregateFunction(FunctionName fnName, List<Type> argTypes, + Type retType, Type intermediateType, boolean hasVarArgs, + URI location, String updateFnSymbol, String initFnSymbol, + String serializeFnSymbol, String mergeFnSymbol, String getValueFnSymbol, + String removeFnSymbol, String finalizeFnSymbol, boolean ignoresDistinct, + boolean isAnalyticFn, boolean returnsNonNullOnEmpty, TFunctionBinaryType binaryType, + boolean userVisible, boolean vectorized, NullableMode nullableMode) { + // only `count` is always not nullable, other aggregate function is always nullable + super(0, fnName, argTypes, retType, hasVarArgs, binaryType, userVisible, vectorized, nullableMode); + setLocation(location); + this.intermediateType = (intermediateType.equals(retType)) ? null : intermediateType; + this.updateFnSymbol = updateFnSymbol; + this.initFnSymbol = initFnSymbol; + this.serializeFnSymbol = serializeFnSymbol; + this.mergeFnSymbol = mergeFnSymbol; + this.getValueFnSymbol = getValueFnSymbol; + this.removeFnSymbol = removeFnSymbol; + this.finalizeFnSymbol = finalizeFnSymbol; Review Comment: I don't know whether should we need to set it in the future(for lateral view / window function)? So make this field settable is conservative -- 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: commits-unsubscr...@doris.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org --------------------------------------------------------------------- To unsubscribe, e-mail: commits-unsubscr...@doris.apache.org For additional commands, e-mail: commits-h...@doris.apache.org