Rollup merge of #113253 - nurmukhametdaniyar:rc_from_cstr_doc_fix, r=Nilstrieb

Fixed documentation of from<CString> for Rc<CStr>: Arc -> Rc

Fix #113131
This commit is contained in:
Matthias Krüger 2023-07-02 23:30:46 +02:00 committed by GitHub
commit 023f72ad5b
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -888,7 +888,7 @@ impl From<&CStr> for Arc<CStr> {
#[stable(feature = "shared_from_slice2", since = "1.24.0")]
impl From<CString> for Rc<CStr> {
/// Converts a [`CString`] into an <code>[Rc]<[CStr]></code> by moving the [`CString`]
/// data into a new [`Arc`] buffer.
/// data into a new [`Rc`] buffer.
#[inline]
fn from(s: CString) -> Rc<CStr> {
let rc: Rc<[u8]> = Rc::from(s.into_inner());