Add std::process

Per [RFC 579](https://github.com/rust-lang/rfcs/pull/579), this commit
adds a new `std::process` module. This module is largely based on the
existing `std::old_io::process` module, but refactors the API to use
`OsStr` and other new standards set out by IO reform.

The existing module is not yet deprecated, to allow for the new API to
get a bit of testing before a mass migration to it.
This commit is contained in:
Aaron Turon
2015-02-06 09:42:57 -08:00
parent 39b463f153
commit 4175f1ce2f
16 changed files with 2051 additions and 36 deletions

View File

@@ -942,6 +942,11 @@ impl PathBuf {
true
}
/// Consume the `PathBuf`, yielding its internal `OsString` storage
pub fn into_os_string(self) -> OsString {
self.inner
}
}
impl<'a, P: ?Sized + 'a> iter::FromIterator<&'a P> for PathBuf where P: AsPath {