Kontinuation commented on code in PR #22663:
URL: https://github.com/apache/datafusion/pull/22663#discussion_r3363894426
##########
datafusion/physical-expr/src/async_scalar_function.rs:
##########
@@ -88,12 +88,8 @@ impl AsyncFuncExpr {
}
/// Return the output field generated by evaluating this function
- pub fn field(&self, input_schema: &Schema) -> Result<Field> {
- Ok(Field::new(
- &self.name,
- self.func.data_type(input_schema)?,
- self.func.nullable(input_schema)?,
- ))
+ pub fn field(&self, _input_schema: &Schema) -> Result<Field> {
+ Ok(self.return_field.as_ref().clone().with_name(&self.name))
Review Comment:
Good idea. I have updated the PR to deprecate `fn field` and implemented `fn
return_field`.
--
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]