diff options
author | 2018-07-14 00:14:02 -0700 | |
---|---|---|
committer | 2018-07-14 00:14:02 -0700 | |
commit | e8af882c479eb063ef6f505cef4e9471b43e9c44 (patch) | |
tree | 97db7853e8b621800c9abbc82940342e0e5d3362 | |
parent | 31d62f417f73d71212201b0cb666380286979646 (diff) | |
download | rust-x86-e8af882c479eb063ef6f505cef4e9471b43e9c44.tar.gz rust-x86-e8af882c479eb063ef6f505cef4e9471b43e9c44.tar.zst rust-x86-e8af882c479eb063ef6f505cef4e9471b43e9c44.zip |
Deny warnings by default.
Signed-off-by: Gerd Zellweger <mail@gerdzellweger.com>
-rw-r--r-- | src/lib.rs | 20 |
1 files changed, 10 insertions, 10 deletions
@@ -1,9 +1,9 @@ -#![cfg(any(target_arch="x86", target_arch="x86_64"))] - +#![cfg(any(target_arch = "x86", target_arch = "x86_64"))] #![feature(const_fn)] #![feature(asm)] #![no_std] #![cfg_attr(test, allow(unused_features))] +#![deny(warnings)] #[macro_use] extern crate bitflags; @@ -22,7 +22,7 @@ macro_rules! check_flag { } macro_rules! bit { - ( $x:expr ) => { + ($x:expr) => { 1 << $x }; } @@ -38,17 +38,17 @@ pub mod irq; pub mod msr; pub mod segmentation; pub mod task; -pub mod tlb; pub mod time; +pub mod tlb; #[cfg(feature = "performance-counter")] pub mod perfcnt; pub mod current { - #[cfg(target_arch="x86")] - pub use bits32::*; - #[cfg(target_arch="x86_64")] - pub use bits64::*; + #[cfg(target_arch = "x86")] + pub use bits32::*; + #[cfg(target_arch = "x86_64")] + pub use bits64::*; } pub mod cpuid { @@ -64,7 +64,7 @@ mod std { #[derive(Copy, Clone, Debug, Eq, PartialEq)] #[repr(u8)] /// x86 Protection levels -/// Note: This should not contain values larger than 2 bits, otherwise +/// Note: This should not contain values larger than 2 bits, otherwise /// segment descriptor code needs to be adjusted accordingly. pub enum Ring { Ring0 = 0b00, @@ -76,4 +76,4 @@ pub enum Ring { #[inline(always)] pub unsafe fn halt() { asm!("hlt" :::: "volatile"); -}
\ No newline at end of file +} |