mbutrovich commented on code in PR #17195:
URL: https://github.com/apache/datafusion/pull/17195#discussion_r2282929076


##########
datafusion/functions/src/regex/regexpreplace.rs:
##########
@@ -94,14 +98,30 @@ impl Default for RegexpReplaceFunc {
 
 impl RegexpReplaceFunc {
     pub fn new() -> Self {
-        use DataType::*;
+        use TypeSignature::*;
+        use TypeSignatureClass::*;
         Self {
             signature: Signature::one_of(
                 vec![
-                    TypeSignature::Exact(vec![Utf8, Utf8, Utf8]),

Review Comment:
   I think that's equivalent to a signature of ```
               signature: Signature::one_of(
                   vec![
                       String(3),
                       String(4)
                   ],
                   Volatility::Immutable,
               ),
   ```
   IIRC I ran into issues with that, but I agree it is simpler.
   



##########
datafusion/functions/src/regex/regexpreplace.rs:
##########
@@ -94,14 +98,30 @@ impl Default for RegexpReplaceFunc {
 
 impl RegexpReplaceFunc {
     pub fn new() -> Self {
-        use DataType::*;
+        use TypeSignature::*;
+        use TypeSignatureClass::*;
         Self {
             signature: Signature::one_of(
                 vec![
-                    TypeSignature::Exact(vec![Utf8, Utf8, Utf8]),

Review Comment:
   I think that's equivalent to a signature of
    ```
               signature: Signature::one_of(
                   vec![
                       String(3),
                       String(4)
                   ],
                   Volatility::Immutable,
               ),
   ```
   IIRC I ran into issues with that, but I agree it is simpler.
   



-- 
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: github-unsubscr...@datafusion.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: github-unsubscr...@datafusion.apache.org
For additional commands, e-mail: github-h...@datafusion.apache.org

Reply via email to