From: bors Date: Tue, 14 Apr 2015 00:07:50 +0000 (+0000) Subject: Auto merge of #24251 - alexcrichton:unsafe-from-raw-fd, r=aturon X-Git-Url: https://git.lizzy.rs/?a=commitdiff_plain;h=e6a812402828f0f11b0de7a7e0c08c1d85a437f1;p=rust.git Auto merge of #24251 - alexcrichton:unsafe-from-raw-fd, r=aturon As pointed out in [RFC issue 1043][rfc] it is quite useful to have the standard I/O types to provide the contract that they are the sole owner of the underlying object they represent. This guarantee enables writing safe interfaces like the `MemoryMap` API sketched out in that issue. [rfc]: https://github.com/rust-lang/rfcs/issues/1043 As constructing objects from these raw handles may end up violating these ownership gurantees, the functions for construction are now marked unsafe. [breaking-change] Closes rust-lang/rfcs#1043 --- e6a812402828f0f11b0de7a7e0c08c1d85a437f1