From e290a8bbaf39e8306498d1bf1926491bcbc67afe Mon Sep 17 00:00:00 2001 From: edef Date: Wed, 26 Aug 2015 00:19:53 +0200 Subject: [PATCH] remove `extern crate core` and prelude imports the latest Rust nightly makes this unnecessary --- src/arch/common.rs | 1 - src/arch/mod.rs | 1 - src/arch/x86_64/mod.rs | 2 -- src/context.rs | 1 - src/debug/mod.rs | 1 - src/lib.rs | 5 +---- src/os/mod.rs | 1 - src/os/sys/unix.rs | 1 - 8 files changed, 1 insertion(+), 12 deletions(-) diff --git a/src/arch/common.rs b/src/arch/common.rs index 8207806..48c4f98 100644 --- a/src/arch/common.rs +++ b/src/arch/common.rs @@ -1,7 +1,6 @@ // This file is part of libfringe, a low-level green threading library. // Copyright (c) 2015, edef // See the LICENSE file included in this distribution. -use core::prelude::*; use core::mem::{size_of, align_of}; use core::cmp::max; use core::ptr; diff --git a/src/arch/mod.rs b/src/arch/mod.rs index 7baca42..d85e3b4 100644 --- a/src/arch/mod.rs +++ b/src/arch/mod.rs @@ -1,7 +1,6 @@ // This file is part of libfringe, a low-level green threading library. // Copyright (c) 2015, edef // See the LICENSE file included in this distribution. -use core::prelude::*; pub use self::imp::Registers; unsafe impl Send for Registers {} diff --git a/src/arch/x86_64/mod.rs b/src/arch/x86_64/mod.rs index 26b674d..3c7e8b5 100644 --- a/src/arch/x86_64/mod.rs +++ b/src/arch/x86_64/mod.rs @@ -1,8 +1,6 @@ // This file is part of libfringe, a low-level green threading library. // Copyright (c) 2015, edef // See the LICENSE file included in this distribution. -use core::prelude::*; - use stack::Stack; use super::common::{push, rust_trampoline}; diff --git a/src/context.rs b/src/context.rs index c66cda6..955915b 100644 --- a/src/context.rs +++ b/src/context.rs @@ -1,7 +1,6 @@ // This file is part of libfringe, a low-level green threading library. // Copyright (c) 2015, edef // See the LICENSE file included in this distribution. -use core::prelude::*; use core::marker::PhantomData; use arch::Registers; use stack; diff --git a/src/debug/mod.rs b/src/debug/mod.rs index 5f0affe..46540ba 100644 --- a/src/debug/mod.rs +++ b/src/debug/mod.rs @@ -1,7 +1,6 @@ // This file is part of libfringe, a low-level green threading library. // Copyright (c) 2015, edef // See the LICENSE file included in this distribution. -use core::prelude::*; use stack; mod valgrind; diff --git a/src/lib.rs b/src/lib.rs index 252a6cb..bb1c9f3 100644 --- a/src/lib.rs +++ b/src/lib.rs @@ -2,15 +2,12 @@ // Copyright (c) 2015, edef // See the LICENSE file included in this distribution. #![feature(no_std)] -#![feature(asm, core, core_prelude)] +#![feature(asm, core)] #![no_std] //! libfringe is a low-level green threading library. //! It provides only a context-swapping mechanism. -#[macro_use] -extern crate core; - #[cfg(test)] #[macro_use] extern crate std; diff --git a/src/os/mod.rs b/src/os/mod.rs index 5935726..38f577b 100644 --- a/src/os/mod.rs +++ b/src/os/mod.rs @@ -3,7 +3,6 @@ // See the LICENSE file included in this distribution. extern crate std; -use core::prelude::*; use self::std::io::Error as IoError; use stack; mod sys; diff --git a/src/os/sys/unix.rs b/src/os/sys/unix.rs index cd26b50..c3d3b64 100644 --- a/src/os/sys/unix.rs +++ b/src/os/sys/unix.rs @@ -2,7 +2,6 @@ // Copyright (c) 2015, edef // See the LICENSE file included in this distribution. extern crate libc; -use core::prelude::*; use self::libc::{c_void, c_int, size_t}; use self::libc::{mmap, mprotect, munmap}; use self::libc::MAP_FAILED;