str.rs: remove "Basic usage" text

Only one example is given
This commit is contained in:
Tshepang Mbambo 2023-08-02 12:14:43 +02:00 committed by GitHub
parent 5cbfee5455
commit 60e43bcf57
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 0 additions and 6 deletions

View File

@ -223,8 +223,6 @@ impl str {
///
/// # Examples
///
/// Basic usage:
///
/// ```
/// let s = "this is a string";
/// let boxed_str = s.to_owned().into_boxed_str();
@ -487,8 +485,6 @@ impl str {
///
/// # Examples
///
/// Basic usage:
///
/// ```
/// let string = String::from("birthday gift");
/// let boxed_str = string.clone().into_boxed_str();
@ -602,8 +598,6 @@ impl str {
///
/// # Examples
///
/// Basic usage:
///
/// ```
/// let smile_utf8 = Box::new([226, 152, 186]);
/// let smile = unsafe { std::str::from_boxed_utf8_unchecked(smile_utf8) };