Skip to content

Commit 34c48db

Browse files
committed
Fix documentation for StrExt::trim_matches
1 parent bfac337 commit 34c48db

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/libcollections/str.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -923,11 +923,11 @@ pub trait StrExt: Index<RangeFull, Output = str> {
923923

924924
/// Returns a string with all pre- and suffixes that match a pattern repeatedly removed.
925925
///
926-
/// The pattern can be a simple `&str`, or a closure that determines the split.
926+
/// The pattern can be any `DoubleEndedSearcher`, including a closure that determines the split.
927927
///
928928
/// # Examples
929929
///
930-
/// Simple `&str` patterns:
930+
/// Simple `char` patterns:
931931
///
932932
/// ```
933933
/// assert_eq!("11foo1bar11".trim_matches('1'), "foo1bar");

0 commit comments

Comments
 (0)