diff options
| author | Alex Crichton <alex@alexcrichton.com> | 2015-04-09 17:42:22 -0700 |
|---|---|---|
| committer | Alex Crichton <alex@alexcrichton.com> | 2015-04-14 10:14:11 -0700 |
| commit | bf4e77d4b543632ca4df8fdd7092850dffc3954b (patch) | |
| tree | c4b56d2a5974e1b3bf4bfc8b7ca1a62d64c2c341 /src/libstd/ffi | |
| parent | dabf0c6371d3b193664f58746fa27c1835a010f3 (diff) | |
| download | rust-bf4e77d4b543632ca4df8fdd7092850dffc3954b.tar.gz rust-bf4e77d4b543632ca4df8fdd7092850dffc3954b.zip | |
std: Remove old_io/old_path/rand modules
This commit entirely removes the old I/O, path, and rand modules. All functionality has been deprecated and unstable for quite some time now!
Diffstat (limited to 'src/libstd/ffi')
| -rw-r--r-- | src/libstd/ffi/c_str.rs | 14 | ||||
| -rw-r--r-- | src/libstd/ffi/os_str.rs | 16 |
2 files changed, 0 insertions, 30 deletions
diff --git a/src/libstd/ffi/c_str.rs b/src/libstd/ffi/c_str.rs index de91e5f3268..d510ee48a16 100644 --- a/src/libstd/ffi/c_str.rs +++ b/src/libstd/ffi/c_str.rs @@ -18,8 +18,6 @@ use io; use iter::Iterator; use libc; use mem; -#[allow(deprecated)] -use old_io; use ops::Deref; use option::Option::{self, Some, None}; use result::Result::{self, Ok, Err}; @@ -245,18 +243,6 @@ impl From<NulError> for io::Error { } } -#[stable(feature = "rust1", since = "1.0.0")] -#[allow(deprecated)] -impl From<NulError> for old_io::IoError { - fn from(_: NulError) -> old_io::IoError { - old_io::IoError { - kind: old_io::IoErrorKind::InvalidInput, - desc: "data provided contains a nul byte", - detail: None - } - } -} - impl CStr { /// Cast a raw C string to a safe C string wrapper. /// diff --git a/src/libstd/ffi/os_str.rs b/src/libstd/ffi/os_str.rs index ab20efe25eb..cc2ba265cd7 100644 --- a/src/libstd/ffi/os_str.rs +++ b/src/libstd/ffi/os_str.rs @@ -42,7 +42,6 @@ use string::String; use ops; use cmp; use hash::{Hash, Hasher}; -use old_path::{Path, GenericPath}; use vec::Vec; use sys::os_str::{Buf, Slice}; @@ -447,21 +446,6 @@ impl AsRef<OsStr> for String { } } -#[allow(deprecated)] -#[stable(feature = "rust1", since = "1.0.0")] -#[deprecated(since = "1.0.0", reason = "trait is deprecated")] -impl AsOsStr for Path { - #[cfg(unix)] - fn as_os_str(&self) -> &OsStr { - unsafe { mem::transmute(self.as_vec()) } - } - #[cfg(windows)] - fn as_os_str(&self) -> &OsStr { - // currently .as_str() is actually infallible on windows - OsStr::from_str(self.as_str().unwrap()) - } -} - impl FromInner<Buf> for OsString { fn from_inner(buf: Buf) -> OsString { OsString { inner: buf } |
