diff options
Diffstat (limited to 'src/libstd')
| -rw-r--r-- | src/libstd/ffi/c_str.rs | 8 | ||||
| -rw-r--r-- | src/libstd/ffi/os_str.rs | 8 | ||||
| -rw-r--r-- | src/libstd/path.rs | 8 |
3 files changed, 12 insertions, 12 deletions
diff --git a/src/libstd/ffi/c_str.rs b/src/libstd/ffi/c_str.rs index 1a91417ca0e..5f0b11a616e 100644 --- a/src/libstd/ffi/c_str.rs +++ b/src/libstd/ffi/c_str.rs @@ -585,11 +585,11 @@ impl From<Box<CStr>> for CString { } } -#[stable(feature = "box_from_c_string", since = "1.18.0")] -impl Into<Box<CStr>> for CString { +#[stable(feature = "box_from_c_string", since = "1.20.0")] +impl From<CString> for Box<CStr> { #[inline] - fn into(self) -> Box<CStr> { - self.into_boxed_c_str() + fn from(s: CString) -> Box<CStr> { + s.into_boxed_c_str() } } diff --git a/src/libstd/ffi/os_str.rs b/src/libstd/ffi/os_str.rs index 42d641706a8..02a13ed7a5a 100644 --- a/src/libstd/ffi/os_str.rs +++ b/src/libstd/ffi/os_str.rs @@ -540,10 +540,10 @@ impl From<Box<OsStr>> for OsString { } } -#[stable(feature = "box_from_os_string", since = "1.18.0")] -impl Into<Box<OsStr>> for OsString { - fn into(self) -> Box<OsStr> { - self.into_boxed_os_str() +#[stable(feature = "box_from_os_string", since = "1.20.0")] +impl From<OsString> for Box<OsStr> { + fn from(s: OsString) -> Box<OsStr> { + s.into_boxed_os_str() } } diff --git a/src/libstd/path.rs b/src/libstd/path.rs index 472ce6bc4fe..e7c7be981d2 100644 --- a/src/libstd/path.rs +++ b/src/libstd/path.rs @@ -1348,10 +1348,10 @@ impl From<Box<Path>> for PathBuf { } } -#[stable(feature = "box_from_path_buf", since = "1.18.0")] -impl Into<Box<Path>> for PathBuf { - fn into(self) -> Box<Path> { - self.into_boxed_path() +#[stable(feature = "box_from_path_buf", since = "1.20.0")] +impl From<PathBuf> for Box<Path> { + fn from(p: PathBuf) -> Box<Path> { + p.into_boxed_path() } } |
