about summary refs log tree commit diff
path: root/src/libstd/ffi
diff options
context:
space:
mode:
authorAlex Crichton <alex@alexcrichton.com>2017-07-20 15:44:35 -0700
committerAlex Crichton <alex@alexcrichton.com>2017-07-25 07:09:31 -0700
commitcbfce40e1cf5e619091fb9b5efd06ed29fa915cd (patch)
treedf7a60a1cf05a41a6372705616c74587a4711800 /src/libstd/ffi
parent46de2af063f976b8b3ac174ee6a0636863fe6a4a (diff)
downloadrust-cbfce40e1cf5e619091fb9b5efd06ed29fa915cd.tar.gz
rust-cbfce40e1cf5e619091fb9b5efd06ed29fa915cd.zip
std: Stabilize CString/OsString/PathBuf extra methods
Stabilizes:

* `CString::as_c_str`
* `CString::into_boxed_c_str`
* `CStr::into_c_string`
* `OsString::into_boxed_os_str`
* `OsStr::into_os_string`
* `PathBuf::into_boxed_path`
* `PathBuf::into_path_buf`

Closes #40380
Diffstat (limited to 'src/libstd/ffi')
-rw-r--r--src/libstd/ffi/c_str.rs6
-rw-r--r--src/libstd/ffi/os_str.rs4
2 files changed, 5 insertions, 5 deletions
diff --git a/src/libstd/ffi/c_str.rs b/src/libstd/ffi/c_str.rs
index 5f0b11a616e..5dd7bb1c0c1 100644
--- a/src/libstd/ffi/c_str.rs
+++ b/src/libstd/ffi/c_str.rs
@@ -462,7 +462,7 @@ impl CString {
     /// assert_eq!(c_str, CStr::from_bytes_with_nul(b"foo\0").unwrap());
     /// ```
     #[inline]
-    #[unstable(feature = "as_c_str", issue = "40380")]
+    #[stable(feature = "as_c_str", since = "1.20.0")]
     pub fn as_c_str(&self) -> &CStr {
         &*self
     }
@@ -482,7 +482,7 @@ impl CString {
     /// let boxed = c_string.into_boxed_c_str();
     /// assert_eq!(&*boxed, CStr::from_bytes_with_nul(b"foo\0").unwrap());
     /// ```
-    #[unstable(feature = "into_boxed_c_str", issue = "40380")]
+    #[stable(feature = "into_boxed_c_str", since = "1.20.0")]
     pub fn into_boxed_c_str(self) -> Box<CStr> {
         unsafe { mem::transmute(self.into_inner()) }
     }
@@ -1009,7 +1009,7 @@ impl CStr {
     /// let boxed = c_string.into_boxed_c_str();
     /// assert_eq!(boxed.into_c_string(), CString::new("foo").unwrap());
     /// ```
-    #[unstable(feature = "into_boxed_c_str", issue = "40380")]
+    #[stable(feature = "into_boxed_c_str", since = "1.20.0")]
     pub fn into_c_string(self: Box<CStr>) -> CString {
         unsafe { mem::transmute(self) }
     }
diff --git a/src/libstd/ffi/os_str.rs b/src/libstd/ffi/os_str.rs
index 02a13ed7a5a..6f147ea0eec 100644
--- a/src/libstd/ffi/os_str.rs
+++ b/src/libstd/ffi/os_str.rs
@@ -260,7 +260,7 @@ impl OsString {
     ///
     /// let b: Box<OsStr> = s.into_boxed_os_str();
     /// ```
-    #[unstable(feature = "into_boxed_os_str", issue = "40380")]
+    #[stable(feature = "into_boxed_os_str", since = "1.20.0")]
     pub fn into_boxed_os_str(self) -> Box<OsStr> {
         unsafe { mem::transmute(self.inner.into_box()) }
     }
@@ -511,7 +511,7 @@ impl OsStr {
     ///
     /// [`Box`]: ../boxed/struct.Box.html
     /// [`OsString`]: struct.OsString.html
-    #[unstable(feature = "into_boxed_os_str", issue = "40380")]
+    #[stable(feature = "into_boxed_os_str", since = "1.20.0")]
     pub fn into_os_string(self: Box<OsStr>) -> OsString {
         let inner: Box<Slice> = unsafe { mem::transmute(self) };
         OsString { inner: Buf::from_box(inner) }