alamb commented on code in PR #18025:
URL: https://github.com/apache/datafusion/pull/18025#discussion_r2504464459


##########
datafusion/functions/src/macros.rs:
##########
@@ -59,6 +59,24 @@ macro_rules! export_functions {
         }
     };
 
+    // function that requires config and takes a vector argument
+    (single $FUNC:ident, $DOC:expr, @config $arg:ident,) => {
+        #[doc = $DOC]
+        pub fn $FUNC($arg: Vec<datafusion_expr::Expr>) -> 
datafusion_expr::Expr {
+            use datafusion_common::config::ConfigOptions;
+            super::$FUNC(&ConfigOptions::default()).call($arg)

Review Comment:
   So then it seems inconsistent in this case -- if we pass the ConfigOptions 
to the constructor that means the function should be using it (in return type 
or simplify). If the options are only needed in `invoke_with_args` why are we 
passing it to the constructor in the first place 🤔 



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

Reply via email to