]> git.lizzy.rs Git - rust.git/commitdiff
Rollup merge of #61715 - RalfJung:test-ascii-lowercase, r=varkor
authorMazdak Farrokhzad <twingoow@gmail.com>
Tue, 11 Jun 2019 15:14:09 +0000 (17:14 +0200)
committerGitHub <noreply@github.com>
Tue, 11 Jun 2019 15:14:09 +0000 (17:14 +0200)
make sure make_ascii_lowercase actually leaves upper-case non-ASCII characters alone

Cc https://github.com/rust-lang/rust/pull/61677 @napen123

src/libcore/str/mod.rs

index 8a128b0d5e7b228075cd1627b7016a2e7e3ef84f..34f2d8917ea472a9f5d25af24e3875448378bedf 100644 (file)
@@ -4000,11 +4000,11 @@ pub fn make_ascii_uppercase(&mut self) {
     /// # Examples
     ///
     /// ```
-    /// let mut s = String::from("Grüße, Jürgen ❤");
+    /// let mut s = String::from("GRÜßE, JÜRGEN ❤");
     ///
     /// s.make_ascii_lowercase();
     ///
-    /// assert_eq!("grüÃ\9fe, jürgen ❤", s);
+    /// assert_eq!("grÃ\9cÃ\9fe, jÃ\9crgen ❤", s);
     /// ```
     #[stable(feature = "ascii_methods_on_intrinsics", since = "1.23.0")]
     pub fn make_ascii_lowercase(&mut self) {