about summary refs log tree commit diff
path: root/src/libstd/lib.rs
diff options
context:
space:
mode:
authorbors <bors@rust-lang.org>2015-11-10 06:56:30 +0000
committerbors <bors@rust-lang.org>2015-11-10 06:56:30 +0000
commit6aee7c5d2c3e5796844671cf072487f6fb04cb9b (patch)
tree955886bbc19c1ce0943377edf689ad4dd1842749 /src/libstd/lib.rs
parent2968dfa28597e50b748b641f9b881c7012b041c6 (diff)
parent3d28b8b98e6e4f55ef4ecd8babf0a050f48a3d11 (diff)
downloadrust-6aee7c5d2c3e5796844671cf072487f6fb04cb9b.tar.gz
rust-6aee7c5d2c3e5796844671cf072487f6fb04cb9b.zip
Auto merge of #29546 - alexcrichton:new-libc, r=brson
This commit replaces the in-tree liblibc with the [external clone](https://github.com/rust-lang-nursery/libc) which has no evolved beyond the in-tree version in light of its [recent redesign](https://github.com/rust-lang/rfcs/pull/1291).

The primary changes here are:

* `src/liblibc/lib.rs` was deleted
* `src/liblibc` is now a submodule pointing at the external repository
* `src/libstd/sys/unix/{c.rs,sync.rs}` were both deleted having all bindings folded into the external liblibc.
* Many ad-hoc `extern` blocks in the standard library were removed in favor of bindings now being in the external liblibc.
* Many functions/types were added to `src/libstd/sys/windows/c.rs`, and the scattered definitions throughout the standard library were consolidated here.

At the API level this commit is **not a breaking change**, although it is only very lightly tested on the *BSD variants and is probably going to break almost all of their builds! Follow-up commits to liblibc should in theory be all that's necessary to get the build working on the *BSDs again.
Diffstat (limited to 'src/libstd/lib.rs')
-rw-r--r--src/libstd/lib.rs30
1 files changed, 16 insertions, 14 deletions
diff --git a/src/libstd/lib.rs b/src/libstd/lib.rs
index 01effcadb3a..a0bb9449806 100644
--- a/src/libstd/lib.rs
+++ b/src/libstd/lib.rs
@@ -213,13 +213,12 @@
        test(no_crate_inject, attr(deny(warnings))),
        test(attr(allow(dead_code, deprecated, unused_variables, unused_mut))))]
 
-// SNAP 1af31d4
-#![allow(unused_features)]
-// SNAP 1af31d4
-#![allow(unused_attributes)]
+#![cfg_attr(stage0, allow(unused_attributes))]
+#![cfg_attr(stage0, allow(improper_ctypes))]
 
 #![feature(alloc)]
 #![feature(allow_internal_unstable)]
+#![feature(asm)]
 #![feature(associated_consts)]
 #![feature(borrow_state)]
 #![feature(box_syntax)]
@@ -233,49 +232,52 @@
 #![feature(core_float)]
 #![feature(core_intrinsics)]
 #![feature(core_simd)]
+#![feature(decode_utf16)]
 #![feature(drain)]
+#![feature(drop_in_place)]
+#![feature(dropck_parametricity)]
+#![feature(float_extras)]
+#![feature(float_from_str_radix)]
 #![feature(fnbox)]
 #![feature(heap_api)]
 #![feature(int_error_internals)]
 #![feature(into_cow)]
 #![feature(lang_items)]
 #![feature(libc)]
-#![feature(linkage, thread_local, asm)]
+#![feature(link_args)]
+#![feature(linkage)]
 #![feature(macro_reexport)]
-#![feature(slice_concat_ext)]
 #![feature(no_std)]
 #![feature(oom)]
 #![feature(optin_builtin_traits)]
 #![feature(placement_in_syntax)]
 #![feature(rand)]
+#![feature(range_inclusive)]
 #![feature(raw)]
 #![feature(reflect_marker)]
 #![feature(slice_bytes)]
+#![feature(slice_concat_ext)]
 #![feature(slice_patterns)]
 #![feature(staged_api)]
 #![feature(str_char)]
 #![feature(str_internals)]
+#![feature(str_utf16)]
+#![feature(test, rustc_private)]
+#![feature(thread_local)]
 #![feature(unboxed_closures)]
 #![feature(unicode)]
 #![feature(unique)]
-#![feature(dropck_parametricity)]
 #![feature(unsafe_no_drop_flag, filling_drop)]
-#![feature(decode_utf16)]
 #![feature(unwind_attributes)]
 #![feature(vec_push_all)]
 #![feature(wrapping)]
 #![feature(zero_one)]
-#![feature(drop_in_place)]
-
-#![cfg_attr(windows, feature(str_utf16))]
-#![cfg_attr(test, feature(float_from_str_radix, range_inclusive, float_extras))]
-#![cfg_attr(test, feature(test, rustc_private))]
-#![cfg_attr(target_env = "msvc", feature(link_args))]
 
 // Don't link to std. We are std.
 #![no_std]
 
 #![deny(missing_docs)]
+#![allow(unused_features)] // std may use features in a platform-specific way
 
 #[cfg(test)] extern crate test;
 #[cfg(test)] #[macro_use] extern crate log;