LarryHu0217 opened a new pull request, #50501: URL: https://github.com/apache/arrow/pull/50501
### Rationale for this change The UTF-8 trim functions only registered kernels for string and large-string inputs. Their exact dispatch therefore rejected dictionary-encoded strings even though the dictionary value type was supported. ### What changes are included in this PR? - Allow the stateful unary string-kernel helper to use a specialized function type. - Decode dictionary input types during dispatch for `utf8_trim`, `utf8_ltrim`, and `utf8_rtrim`. - Add regression coverage for dictionary-encoded string and large-string arrays, including nulls. ### Are these changes tested? - `arrow-compute-scalar-type-test --gtest_filter='*TrimUTF8*'` (4 passed) - `arrow-compute-scalar-type-test --gtest_brief=1` (344 passed, 1 pre-existing disabled test) - C++ Debug build with warnings treated as errors - `clang-format` 18.1.8 and `cpplint` 1.6.1 ### Are there any user-facing changes? Yes. The three UTF-8 trim functions now accept dictionary-encoded string inputs and return decoded string arrays. There are no public API signature changes. ### AI-assisted development OpenAI Codex assisted with reproducing the issue, implementing the patch, and drafting the regression tests. The change was checked against Arrow's existing dictionary-dispatch patterns and validated with the commands above. -- 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]
