diff options
| author | Alex Crichton <alex@alexcrichton.com> | 2015-07-15 23:31:24 -0700 |
|---|---|---|
| committer | Alex Crichton <alex@alexcrichton.com> | 2015-07-20 09:08:50 -0700 |
| commit | 7e9e3896dfcef4852ca8ad90f91baf5187b0248e (patch) | |
| tree | 105314b0a9e49abc7727c38c2dff96fd8d454545 /src/libstd/sys/windows/process.rs | |
| parent | 4e51763e6428580f2b3275cd7076492376801a1e (diff) | |
| download | rust-7e9e3896dfcef4852ca8ad90f91baf5187b0248e.tar.gz rust-7e9e3896dfcef4852ca8ad90f91baf5187b0248e.zip | |
std: Add IntoRaw{Fd,Handle,Socket} traits
This commit is an implementation of [RFC 1174][rfc] which adds three new traits to the standard library: * `IntoRawFd` - implemented on Unix for all I/O types (files, sockets, etc) * `IntoRawHandle` - implemented on Windows for files, processes, etc * `IntoRawSocket` - implemented on Windows for networking types [rfc]: https://github.com/rust-lang/rfcs/blob/master/text/1174-into-raw-fd-socket-handle-traits.md Closes #27062
Diffstat (limited to 'src/libstd/sys/windows/process.rs')
| -rw-r--r-- | src/libstd/sys/windows/process.rs | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/src/libstd/sys/windows/process.rs b/src/libstd/sys/windows/process.rs index 0b0268d4746..ca33e11eea0 100644 --- a/src/libstd/sys/windows/process.rs +++ b/src/libstd/sys/windows/process.rs @@ -220,6 +220,8 @@ impl Process { } pub fn handle(&self) -> &Handle { &self.handle } + + pub fn into_handle(self) -> Handle { self.handle } } #[derive(PartialEq, Eq, Clone, Copy, Debug)] |
