@@ -1832,14 +1832,14 @@ impl str {
1832
1832
/// Returns a string slice with leading and trailing whitespace removed.
1833
1833
///
1834
1834
/// 'Whitespace' is defined according to the terms of the Unicode Derived
1835
- /// Core Property `White_Space`.
1835
+ /// Core Property `White_Space`, which includes newlines .
1836
1836
///
1837
1837
/// # Examples
1838
1838
///
1839
1839
/// Basic usage:
1840
1840
///
1841
1841
/// ```
1842
- /// let s = " Hello\tworld\t";
1842
+ /// let s = "\n Hello\tworld\t\n ";
1843
1843
///
1844
1844
/// assert_eq!("Hello\tworld", s.trim());
1845
1845
/// ```
@@ -1855,7 +1855,7 @@ impl str {
1855
1855
/// Returns a string slice with leading whitespace removed.
1856
1856
///
1857
1857
/// 'Whitespace' is defined according to the terms of the Unicode Derived
1858
- /// Core Property `White_Space`.
1858
+ /// Core Property `White_Space`, which includes newlines .
1859
1859
///
1860
1860
/// # Text directionality
1861
1861
///
@@ -1869,8 +1869,8 @@ impl str {
1869
1869
/// Basic usage:
1870
1870
///
1871
1871
/// ```
1872
- /// let s = " Hello\tworld\t";
1873
- /// assert_eq!("Hello\tworld\t", s.trim_start());
1872
+ /// let s = "\n Hello\tworld\t\n ";
1873
+ /// assert_eq!("Hello\tworld\t\n ", s.trim_start());
1874
1874
/// ```
1875
1875
///
1876
1876
/// Directionality:
@@ -1894,7 +1894,7 @@ impl str {
1894
1894
/// Returns a string slice with trailing whitespace removed.
1895
1895
///
1896
1896
/// 'Whitespace' is defined according to the terms of the Unicode Derived
1897
- /// Core Property `White_Space`.
1897
+ /// Core Property `White_Space`, which includes newlines .
1898
1898
///
1899
1899
/// # Text directionality
1900
1900
///
@@ -1908,8 +1908,8 @@ impl str {
1908
1908
/// Basic usage:
1909
1909
///
1910
1910
/// ```
1911
- /// let s = " Hello\tworld\t";
1912
- /// assert_eq!(" Hello\tworld", s.trim_end());
1911
+ /// let s = "\n Hello\tworld\t\n ";
1912
+ /// assert_eq!("\n Hello\tworld", s.trim_end());
1913
1913
/// ```
1914
1914
///
1915
1915
/// Directionality:
0 commit comments