Should predicate functions warn when called with a function that is not a predicate? #470
Passing a function that returns a logical vector as the predicate argument to predicate functions can cause unexpected results, as in the example below, from this StackOverflow question.
purrr::every(list(1:10), is.na) #>  TRUE
Perhaps adding a warning message if the predicate evaluates to a logical vector of length > 1 would be appropriate?
The text was updated successfully, but these errors were encountered: