diff options
| author | Frank Steffahn <frank.steffahn@stu.uni-kiel.de> | 2021-03-31 12:24:37 +0200 |
|---|---|---|
| committer | Frank Steffahn <frank.steffahn@stu.uni-kiel.de> | 2021-03-31 16:02:59 +0200 |
| commit | f5e7dbb20a4090f089f09a116ab7a75ad4296398 (patch) | |
| tree | 04d7f18ee3db9da7857cff37753fd1c9f356561c | |
| parent | e7821e5475b0628eb9cb87534dad131c577de03c (diff) | |
| download | rust-f5e7dbb20a4090f089f09a116ab7a75ad4296398.tar.gz rust-f5e7dbb20a4090f089f09a116ab7a75ad4296398.zip | |
Add a few missing links, fix a typo
| -rw-r--r-- | library/std/src/ffi/os_str.rs | 2 | ||||
| -rw-r--r-- | library/std/src/path.rs | 14 |
2 files changed, 8 insertions, 8 deletions
diff --git a/library/std/src/ffi/os_str.rs b/library/std/src/ffi/os_str.rs index 6fc97d628d7..ecaab670349 100644 --- a/library/std/src/ffi/os_str.rs +++ b/library/std/src/ffi/os_str.rs @@ -858,7 +858,7 @@ impl From<Cow<'_, OsStr>> for Box<OsStr> { #[stable(feature = "os_string_from_box", since = "1.18.0")] impl From<Box<OsStr>> for OsString { - /// Converts a [`Box`]`<`[`OsStr`]`>` into a `OsString` without copying or + /// Converts a [`Box`]`<`[`OsStr`]`>` into an [`OsString`] without copying or /// allocating. #[inline] fn from(boxed: Box<OsStr>) -> OsString { diff --git a/library/std/src/path.rs b/library/std/src/path.rs index 57c892f32b1..984c9b41567 100644 --- a/library/std/src/path.rs +++ b/library/std/src/path.rs @@ -1467,7 +1467,7 @@ impl<T: ?Sized + AsRef<OsStr>> From<&T> for PathBuf { #[stable(feature = "rust1", since = "1.0.0")] impl From<OsString> for PathBuf { - /// Converts a `OsString` into a `PathBuf` + /// Converts a [`OsString`] into a [`PathBuf`] /// /// This conversion does not allocate or copy memory. #[inline] @@ -1478,7 +1478,7 @@ impl From<OsString> for PathBuf { #[stable(feature = "from_path_buf_for_os_string", since = "1.14.0")] impl From<PathBuf> for OsString { - /// Converts a `PathBuf` into a `OsString` + /// Converts a [`PathBuf`] into a [`OsString`] /// /// This conversion does not allocate or copy memory. #[inline] @@ -1489,7 +1489,7 @@ impl From<PathBuf> for OsString { #[stable(feature = "rust1", since = "1.0.0")] impl From<String> for PathBuf { - /// Converts a `String` into a `PathBuf` + /// Converts a [`String`] into a [`PathBuf`] /// /// This conversion does not allocate or copy memory. #[inline] @@ -1595,7 +1595,7 @@ impl<'a> From<Cow<'a, Path>> for PathBuf { #[stable(feature = "shared_from_slice2", since = "1.24.0")] impl From<PathBuf> for Arc<Path> { - /// Converts a `PathBuf` into an `Arc` by moving the `PathBuf` data into a new `Arc` buffer. + /// Converts a [`PathBuf`] into an [`Arc`] by moving the [`PathBuf`] data into a new [`Arc`] buffer. #[inline] fn from(s: PathBuf) -> Arc<Path> { let arc: Arc<OsStr> = Arc::from(s.into_os_string()); @@ -1605,7 +1605,7 @@ impl From<PathBuf> for Arc<Path> { #[stable(feature = "shared_from_slice2", since = "1.24.0")] impl From<&Path> for Arc<Path> { - /// Converts a `Path` into an `Arc` by copying the `Path` data into a new `Arc` buffer. + /// Converts a [`Path`] into an [`Arc`] by copying the [`Path`] data into a new [`Arc`] buffer. #[inline] fn from(s: &Path) -> Arc<Path> { let arc: Arc<OsStr> = Arc::from(s.as_os_str()); @@ -1615,7 +1615,7 @@ impl From<&Path> for Arc<Path> { #[stable(feature = "shared_from_slice2", since = "1.24.0")] impl From<PathBuf> for Rc<Path> { - /// Converts a `PathBuf` into an `Rc` by moving the `PathBuf` data into a new `Rc` buffer. + /// Converts a [`PathBuf`] into an [`Rc`] by moving the [`PathBuf`] data into a new `Rc` buffer. #[inline] fn from(s: PathBuf) -> Rc<Path> { let rc: Rc<OsStr> = Rc::from(s.into_os_string()); @@ -1625,7 +1625,7 @@ impl From<PathBuf> for Rc<Path> { #[stable(feature = "shared_from_slice2", since = "1.24.0")] impl From<&Path> for Rc<Path> { - /// Converts a `Path` into an `Rc` by copying the `Path` data into a new `Rc` buffer. + /// Converts a [`Path`] into an [`Rc`] by copying the [`Path`] data into a new `Rc` buffer. #[inline] fn from(s: &Path) -> Rc<Path> { let rc: Rc<OsStr> = Rc::from(s.as_os_str()); |
