Skip to content

Commit 49e5381

Browse files
Rollup merge of rust-lang#41860 - mbrubeck:docs, r=nagisa
Remove wrong or outdated info from CString docs. None
2 parents 2398241 + defcfb2 commit 49e5381

File tree

1 file changed

+4
-6
lines changed

1 file changed

+4
-6
lines changed

src/libstd/ffi/c_str.rs

+4-6
Original file line numberDiff line numberDiff line change
@@ -30,12 +30,10 @@ use str::{self, Utf8Error};
3030
/// type is a static guarantee that the underlying bytes contain no interior 0
3131
/// bytes and the final byte is 0.
3232
///
33-
/// A `CString` is created from either a byte slice or a byte vector. After
34-
/// being created, a `CString` predominately inherits all of its methods from
35-
/// the `Deref` implementation to `[c_char]`. Note that the underlying array
36-
/// is represented as an array of `c_char` as opposed to `u8`. A `u8` slice
37-
/// can be obtained with the `as_bytes` method. Slices produced from a `CString`
38-
/// do *not* contain the trailing nul terminator unless otherwise specified.
33+
/// A `CString` is created from either a byte slice or a byte vector. A `u8`
34+
/// slice can be obtained with the `as_bytes` method. Slices produced from a
35+
/// `CString` do *not* contain the trailing nul terminator unless otherwise
36+
/// specified.
3937
///
4038
/// # Examples
4139
///

0 commit comments

Comments
 (0)