You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The documentation for str_detect and str_subset should be updated to say that pattern cannot be empty or boundary().
Currently both say "An empty pattern, "", is equivalent to boundary("character")", implying that they will accept a boundary() as the pattern, but this gives an error as below.
> fruit <- c("apple", "banana", "pear", "pineapple")
> str_subset(fruit, "")
Error in `str_subset()`:
! `pattern` can't be the empty string (`""`).
> fruit <- c("apple", "banana", "pear", "pineapple")
> str_subset(fruit, boundary("character"))
Error in `str_subset()`:
! `pattern` can't be a boundary.
The text was updated successfully, but these errors were encountered:
To fix this documentation issue for TDD, you'll need to identify the five functions that forbit both empty and boundary patterns and create a new @param pattern docstring for them to inherit from instead of str_detect().
The documentation for str_detect and str_subset should be updated to say that pattern cannot be empty or boundary().
Currently both say "An empty pattern, "", is equivalent to boundary("character")", implying that they will accept a boundary() as the pattern, but this gives an error as below.
The text was updated successfully, but these errors were encountered: