edponce commented on a change in pull request #11233:
URL: https://github.com/apache/arrow/pull/11233#discussion_r717307464
##########
File path: cpp/src/arrow/compute/kernels/scalar_string.cc
##########
@@ -2201,11 +2201,11 @@ void AddSplitWhitespaceAscii(FunctionRegistry*
registry) {
auto func =
std::make_shared<ScalarFunction>("ascii_split_whitespace",
Arity::Unary(),
&ascii_split_whitespace_doc,
&default_options);
- using t32 = SplitWhitespaceAsciiExec<StringType, ListType>;
- using t64 = SplitWhitespaceAsciiExec<LargeStringType, ListType>;
- DCHECK_OK(func->AddKernel({utf8()}, {list(utf8())}, t32::Exec,
t32::State::Init));
- DCHECK_OK(
- func->AddKernel({large_utf8()}, {list(large_utf8())}, t64::Exec,
t64::State::Init));
+
+ for (const auto& ty : StringTypes()) {
+ auto exec = GenerateTypeAgnosticVarBinary<SplitWhitespaceAsciiExec,
ListType>(ty);
+ DCHECK_OK(func->AddKernel({ty}, {list(ty)}, exec, SplitState::Init));
+ }
Review comment:
Created [ARROW-14151](https://issues.apache.org/jira/browse/ARROW-14151)
for the ASCII functions.
--
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]