ateucher opened a new pull request #12711:
URL: https://github.com/apache/arrow/pull/12711


   This ensures that the `grepl` binding mimics R's base `grepl` by returning 
`FALSE` for `NA` inputs (previously it returned `NA`). As several other 
bindings called the `grepl` binding and we don't want the `grepl` behaviour 
with `NA` to propagate to those bindings (they all return `NA` with `NA` 
inputs), I had to change how they were constructed as well. I abstracted out 
the main parts of the `register_binding` for the string matching functions 
(those that return a `logical`) into a helper function 
`create_string_match_expr()`, which is used by the bindings for `grepl`, 
`str_detect`, `str_starts`, and `str_ends`.
   
   I added several tests for `NA` behaviour - which [failed before the 
changes](https://github.com/ateucher/arrow/actions/runs/2037010015) and now 
pass (at least locally, will wait for CI to finish here)


-- 
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...@arrow.apache.org

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


Reply via email to