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
/// Replaces the leftmost occurrence of a pattern with another string, in-place.
1989
+
///
1990
+
/// This method should be preferred over [`String::replacen(..., 1)`](str::replacen) as it can use the `String`'s existing capacity to prevent a reallocation if sufficient space is available.
1991
+
///
1992
+
/// # Examples
1993
+
///
1994
+
/// Basic usage:
1995
+
///
1996
+
/// ```
1997
+
/// #![feature(string_replace_in_place)]
1998
+
///
1999
+
/// let mut s = String::from("Test Results: ❌❌❌");
0 commit comments