error[E0631]: type mismatch in function arguments
--> src/lib.rs:7:26
|
7 | .map(|word| word.trim_end_matches(char::is_ascii_punctuation))
| ^^^^^^^^^^^^^^^^
| |
| expected signature of `fn(char) -> _`
| found signature of `for<'r> fn(&'r char) -> _`
|
= note: required because of the requirements on the impl of `std::str::pattern::Pattern<'_>` for `for<'r> fn(&'r char) -> bool {std::char::methods::<impl char>::is_ascii_punctuation}`