comphead commented on code in PR #9438:
URL: https://github.com/apache/arrow-datafusion/pull/9438#discussion_r1511491343
##########
docs/source/contributor-guide/index.md:
##########
@@ -249,22 +249,23 @@ These are valuable for comparative evaluation against
alternative Arrow implemen
Below is a checklist of what you need to do to add a new scalar function to
DataFusion:
-- Add the actual implementation of the function:
- - [here](../../../datafusion/physical-expr/src/string_expressions.rs) for
string functions
- - [here](../../../datafusion/physical-expr/src/math_expressions.rs) for math
functions
- - [here](../../../datafusion/physical-expr/src/datetime_expressions.rs) for
datetime functions
- - create a new module [here](../../../datafusion/physical-expr/src) for
other functions
-- In [physical-expr/src](../../../datafusion/physical-expr/src/functions.rs),
add:
- - a new variant to `BuiltinScalarFunction`
- - a new entry to `FromStr` with the name of the function as called by SQL
- - a new line in `return_type` with the expected return type of the function,
given an incoming type
- - a new line in `signature` with the signature of the function (number and
types of its arguments)
- - a new line in `create_physical_expr`/`create_physical_fun` mapping the
built-in to the implementation
- - tests to the function.
+- Add the actual implementation of the function to a new module file within:
+ - [here](../../../datafusion/functions-array/src) for array functions
+ - [here](../../../datafusion/functions/src/datetime) for datetime functions
+ - [here](../../../datafusion/functions/src/encoding) for encoding functions
+ - [here](../../../datafusion/functions/src/math) for math functions
+ - [here](../../../datafusion/functions/src/regex) for regex functions
+ - [here](../../../datafusion/functions/src/string) for string functions
+ - create a new module [here](../../../datafusion/functions/src) for other
functions. New function modules should likely have their own feature flag.
Review Comment:
```suggestion
- create a new module [here](../../../datafusion/functions/src) for other
functions.
```
This is slightly unclear as for me... Or we probably need to find better
statement
--
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]