Skip to content

Commit

Permalink
Fix build of rustc-dep-of-std feature
Browse files Browse the repository at this point in the history
Enusre that `no_core` is turned on, and while here update the `no_std`
header to be unconditionally applied.

Closes rust-lang#1267
  • Loading branch information
alexcrichton committed Feb 21, 2019
1 parent 577fdc8 commit 5049a97
Showing 1 changed file with 3 additions and 9 deletions.
12 changes: 3 additions & 9 deletions src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -20,17 +20,11 @@
// Enable extra lints:
#![cfg_attr(feature = "extra_traits", deny(missing_debug_implementations))]
#![deny(missing_copy_implementations, safe_packed_borrows)]
// Enable no_std:
#![cfg_attr(
not(any(
feature = "use_std",
feature = "rustc-dep-of-std",
)),
no_std
)]
#![no_std]
#![cfg_attr(feature = "rustc-dep-of-std", no_core)]

#[cfg(feature = "use_std")]
extern crate std as core;
extern crate std;

#[macro_use]
mod macros;
Expand Down

0 comments on commit 5049a97

Please sign in to comment.