diff options
| author | bors <bors@rust-lang.org> | 2014-03-28 17:16:48 -0700 |
|---|---|---|
| committer | bors <bors@rust-lang.org> | 2014-03-28 17:16:48 -0700 |
| commit | ff733c767a2ac48e5f94a37bc8ed3d2f1bc1141c (patch) | |
| tree | f398acb54f2432247f3c174555010b3055cd7133 /src/libstd | |
| parent | cbfc0a5e33eb3d97a2995d120536b8dadc0cc0a2 (diff) | |
| parent | 451e8c1c6178750a4c1789f40749562164a980b7 (diff) | |
| download | rust-ff733c767a2ac48e5f94a37bc8ed3d2f1bc1141c.tar.gz rust-ff733c767a2ac48e5f94a37bc8ed3d2f1bc1141c.zip | |
auto merge of #13162 : alexcrichton/rust/attr-syntax, r=brson
This is the rebasing of #13068 with a fix for #13067 as the first commit.
Diffstat (limited to 'src/libstd')
61 files changed, 89 insertions, 89 deletions
diff --git a/src/libstd/cleanup.rs b/src/libstd/cleanup.rs index 243f7b2055f..2e51931f15a 100644 --- a/src/libstd/cleanup.rs +++ b/src/libstd/cleanup.rs @@ -8,7 +8,7 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -#[doc(hidden)]; +#![doc(hidden)] use ptr; use raw; diff --git a/src/libstd/cmp.rs b/src/libstd/cmp.rs index e956a1cdf1d..a8d5aa6e38e 100644 --- a/src/libstd/cmp.rs +++ b/src/libstd/cmp.rs @@ -20,7 +20,7 @@ and `Eq` to overload the `==` and `!=` operators. */ -#[allow(missing_doc)]; +#![allow(missing_doc)] /** * Trait for values that can be compared for equality and inequality. diff --git a/src/libstd/comm/mod.rs b/src/libstd/comm/mod.rs index 94e3d5ce2d3..ef8894a258c 100644 --- a/src/libstd/comm/mod.rs +++ b/src/libstd/comm/mod.rs @@ -252,7 +252,7 @@ use sync::arc::UnsafeArc; pub use comm::select::{Select, Handle}; macro_rules! test ( - { fn $name:ident() $b:block $($a:attr)*} => ( + { fn $name:ident() $b:block $(#[$a:meta])*} => ( mod $name { #[allow(unused_imports)]; @@ -265,8 +265,8 @@ macro_rules! test ( fn f() $b - $($a)* #[test] fn uv() { f() } - $($a)* #[test] fn native() { + $(#[$a])* #[test] fn uv() { f() } + $(#[$a])* #[test] fn native() { use native; let (tx, rx) = channel(); native::task::spawn(proc() { tx.send(f()) }); diff --git a/src/libstd/comm/select.rs b/src/libstd/comm/select.rs index 1b2e79e02b4..23bbb5a5611 100644 --- a/src/libstd/comm/select.rs +++ b/src/libstd/comm/select.rs @@ -43,7 +43,7 @@ //! } //! ``` -#[allow(dead_code)]; +#![allow(dead_code)] use cast; use cell::Cell; diff --git a/src/libstd/fmt/rt.rs b/src/libstd/fmt/rt.rs index 89895f30585..2a2515754b4 100644 --- a/src/libstd/fmt/rt.rs +++ b/src/libstd/fmt/rt.rs @@ -14,8 +14,8 @@ //! These definitions are similar to their `ct` equivalents, but differ in that //! these can be statically allocated and are slightly optimized for the runtime -#[allow(missing_doc)]; -#[doc(hidden)]; +#![allow(missing_doc)] +#![doc(hidden)] use fmt::parse; use option::Option; diff --git a/src/libstd/gc.rs b/src/libstd/gc.rs index 7fb23d77f3c..06a864f9a10 100644 --- a/src/libstd/gc.rs +++ b/src/libstd/gc.rs @@ -16,7 +16,7 @@ collector is task-local so `Gc<T>` is not sendable. */ -#[allow(experimental)]; +#![allow(experimental)] use kinds::marker; use clone::Clone; diff --git a/src/libstd/hash/mod.rs b/src/libstd/hash/mod.rs index dc7d5c5b9c7..5e63f59f761 100644 --- a/src/libstd/hash/mod.rs +++ b/src/libstd/hash/mod.rs @@ -61,7 +61,7 @@ * ``` */ -#[allow(unused_must_use)]; +#![allow(unused_must_use)] use container::Container; use io::Writer; diff --git a/src/libstd/intrinsics.rs b/src/libstd/intrinsics.rs index 1da9a3a7103..988140d38d4 100644 --- a/src/libstd/intrinsics.rs +++ b/src/libstd/intrinsics.rs @@ -41,7 +41,7 @@ A quick refresher on memory ordering: */ -#[allow(missing_doc)]; +#![allow(missing_doc)] // This is needed to prevent duplicate lang item definitions. #[cfg(test)] diff --git a/src/libstd/io/extensions.rs b/src/libstd/io/extensions.rs index b9e933d0b14..0275d9ba8d9 100644 --- a/src/libstd/io/extensions.rs +++ b/src/libstd/io/extensions.rs @@ -10,7 +10,7 @@ //! Utility mixins that apply to all Readers and Writers -#[allow(missing_doc)]; +#![allow(missing_doc)] // FIXME: Not sure how this should be structured // FIXME: Iteration should probably be considered separately diff --git a/src/libstd/io/mod.rs b/src/libstd/io/mod.rs index 3e193f246a8..c1833e6b116 100644 --- a/src/libstd/io/mod.rs +++ b/src/libstd/io/mod.rs @@ -208,7 +208,7 @@ responding to errors that may occur while attempting to read the numbers. */ -#[deny(unused_must_use)]; +#![deny(unused_must_use)] use cast; use char::Char; diff --git a/src/libstd/io/net/addrinfo.rs b/src/libstd/io/net/addrinfo.rs index 6e0b766a587..f16db6e76c9 100644 --- a/src/libstd/io/net/addrinfo.rs +++ b/src/libstd/io/net/addrinfo.rs @@ -17,7 +17,7 @@ getaddrinfo() */ -#[allow(missing_doc)]; +#![allow(missing_doc)] use io::IoResult; use io::net::ip::{SocketAddr, IpAddr}; diff --git a/src/libstd/io/net/ip.rs b/src/libstd/io/net/ip.rs index fef4dd380e8..8cb205ab67e 100644 --- a/src/libstd/io/net/ip.rs +++ b/src/libstd/io/net/ip.rs @@ -13,7 +13,7 @@ //! This module contains functions useful for parsing, formatting, and //! manipulating IP addresses. -#[allow(missing_doc)]; +#![allow(missing_doc)] use container::Container; use fmt; diff --git a/src/libstd/io/net/tcp.rs b/src/libstd/io/net/tcp.rs index e343fdcd325..61943eb3d6f 100644 --- a/src/libstd/io/net/tcp.rs +++ b/src/libstd/io/net/tcp.rs @@ -17,7 +17,7 @@ //! A TCP connection implements the `Reader` and `Writer` traits, while the TCP //! listener (socket server) implements the `Listener` and `Acceptor` traits. -#[deny(missing_doc)]; +#![deny(missing_doc)] use clone::Clone; use io::IoResult; diff --git a/src/libstd/io/net/unix.rs b/src/libstd/io/net/unix.rs index 1a020f9a820..73bb6b56298 100644 --- a/src/libstd/io/net/unix.rs +++ b/src/libstd/io/net/unix.rs @@ -22,7 +22,7 @@ instances as clients. */ -#[allow(missing_doc)]; +#![allow(missing_doc)] use prelude::*; diff --git a/src/libstd/io/pipe.rs b/src/libstd/io/pipe.rs index fbf79b19445..43b53ca95dc 100644 --- a/src/libstd/io/pipe.rs +++ b/src/libstd/io/pipe.rs @@ -13,7 +13,7 @@ //! Currently these aren't particularly useful, there only exists bindings //! enough so that pipes can be created to child processes. -#[allow(missing_doc)]; +#![allow(missing_doc)] use prelude::*; use io::IoResult; diff --git a/src/libstd/io/process.rs b/src/libstd/io/process.rs index 4f4d2d793f6..0ce35018a9c 100644 --- a/src/libstd/io/process.rs +++ b/src/libstd/io/process.rs @@ -10,7 +10,7 @@ //! Bindings for executing child processes -#[deny(missing_doc)]; +#![deny(missing_doc)] use prelude::*; diff --git a/src/libstd/io/test.rs b/src/libstd/io/test.rs index 9eeaf4635a4..d5bd7ad24f8 100644 --- a/src/libstd/io/test.rs +++ b/src/libstd/io/test.rs @@ -10,7 +10,7 @@ /*! Various utility functions useful for writing I/O tests */ -#[macro_escape]; +#![macro_escape] use libc; use os; @@ -19,7 +19,7 @@ use std::io::net::ip::*; use sync::atomics::{AtomicUint, INIT_ATOMIC_UINT, Relaxed}; macro_rules! iotest ( - { fn $name:ident() $b:block $($a:attr)* } => ( + { fn $name:ident() $b:block $(#[$a:meta])* } => ( mod $name { #[allow(unused_imports)]; @@ -43,8 +43,8 @@ macro_rules! iotest ( fn f() $b - $($a)* #[test] fn green() { f() } - $($a)* #[test] fn native() { + $(#[$a])* #[test] fn green() { f() } + $(#[$a])* #[test] fn native() { use native; let (tx, rx) = channel(); native::task::spawn(proc() { tx.send(f()) }); diff --git a/src/libstd/lib.rs b/src/libstd/lib.rs index 9e13d70b0ce..c130b89b6d4 100644 --- a/src/libstd/lib.rs +++ b/src/libstd/lib.rs @@ -43,21 +43,21 @@ //! //! use std::prelude::*; -#[crate_id = "std#0.10-pre"]; -#[comment = "The Rust standard library"]; -#[license = "MIT/ASL2"]; -#[crate_type = "rlib"]; -#[crate_type = "dylib"]; -#[doc(html_logo_url = "http://www.rust-lang.org/logos/rust-logo-128x128-blk-v2.png", - html_favicon_url = "http://www.rust-lang.org/favicon.ico", - html_root_url = "http://static.rust-lang.org/doc/master")]; -#[feature(macro_rules, globs, asm, managed_boxes, thread_local, link_args, - simd, linkage, default_type_params, phase)]; +#![crate_id = "std#0.10-pre"] +#![comment = "The Rust standard library"] +#![license = "MIT/ASL2"] +#![crate_type = "rlib"] +#![crate_type = "dylib"] +#![doc(html_logo_url = "http://www.rust-lang.org/logos/rust-logo-128x128-blk-v2.png", + html_favicon_url = "http://www.rust-lang.org/favicon.ico", + html_root_url = "http://static.rust-lang.org/doc/master")] +#![feature(macro_rules, globs, asm, managed_boxes, thread_local, link_args, + simd, linkage, default_type_params, phase)] // Don't link to std. We are std. -#[no_std]; +#![no_std] -#[deny(missing_doc)]; +#![deny(missing_doc)] // When testing libstd, bring in libuv as the I/O backend so tests can print // things and all of the std::io tests have an I/O interface to run on top diff --git a/src/libstd/libc.rs b/src/libstd/libc.rs index 83a95952e02..a310b95a213 100644 --- a/src/libstd/libc.rs +++ b/src/libstd/libc.rs @@ -62,10 +62,10 @@ * dissolved. */ -#[allow(non_camel_case_types)]; -#[allow(non_uppercase_statics)]; -#[allow(missing_doc)]; -#[allow(uppercase_variables)]; +#![allow(non_camel_case_types)] +#![allow(non_uppercase_statics)] +#![allow(missing_doc)] +#![allow(uppercase_variables)] // Initial glob-exports mean that all the contents of all the modules // wind up exported, if you're interested in writing platform-specific code. diff --git a/src/libstd/macros.rs b/src/libstd/macros.rs index d183fae3ac6..9b1c5a406cf 100644 --- a/src/libstd/macros.rs +++ b/src/libstd/macros.rs @@ -14,7 +14,7 @@ //! library. Each macro is available for use when linking against the standard //! library. -#[macro_escape]; +#![macro_escape] /// The entry point for failure of rust tasks. /// diff --git a/src/libstd/mem.rs b/src/libstd/mem.rs index 1f0a3b5b0bd..0e709445770 100644 --- a/src/libstd/mem.rs +++ b/src/libstd/mem.rs @@ -13,7 +13,7 @@ //! This module contains functions for querying the size and alignment of //! types, initializing and manipulating memory. -#[allow(missing_doc)]; // FIXME +#![allow(missing_doc)] // FIXME use cast; use ptr; diff --git a/src/libstd/num/cmath.rs b/src/libstd/num/cmath.rs index 13c4a812ec4..32864f14c96 100644 --- a/src/libstd/num/cmath.rs +++ b/src/libstd/num/cmath.rs @@ -8,8 +8,8 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -#[allow(missing_doc)]; -#[allow(dead_code)]; +#![allow(missing_doc)] +#![allow(dead_code)] //! Bindings for the C math library (for basic mathematic functions) diff --git a/src/libstd/num/f32.rs b/src/libstd/num/f32.rs index 323f24a52c3..99484f41de1 100644 --- a/src/libstd/num/f32.rs +++ b/src/libstd/num/f32.rs @@ -10,7 +10,7 @@ //! Operations and constants for 32-bits floats (`f32` type) -#[allow(missing_doc)]; +#![allow(missing_doc)] use prelude::*; diff --git a/src/libstd/num/f64.rs b/src/libstd/num/f64.rs index fc8c5f47073..4029e111b08 100644 --- a/src/libstd/num/f64.rs +++ b/src/libstd/num/f64.rs @@ -10,7 +10,7 @@ //! Operations and constants for 64-bits floats (`f64` type) -#[allow(missing_doc)]; +#![allow(missing_doc)] use prelude::*; diff --git a/src/libstd/num/float_macros.rs b/src/libstd/num/float_macros.rs index 7c93602af11..3e403219a4f 100644 --- a/src/libstd/num/float_macros.rs +++ b/src/libstd/num/float_macros.rs @@ -8,8 +8,8 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -#[macro_escape]; -#[doc(hidden)]; +#![macro_escape] +#![doc(hidden)] macro_rules! assert_approx_eq( ($a:expr, $b:expr) => ({ diff --git a/src/libstd/num/i16.rs b/src/libstd/num/i16.rs index 0ecb55e5106..42710a8b459 100644 --- a/src/libstd/num/i16.rs +++ b/src/libstd/num/i16.rs @@ -10,7 +10,7 @@ //! Operations and constants for signed 16-bits integers (`i16` type) -#[allow(non_uppercase_statics)]; +#![allow(non_uppercase_statics)] use prelude::*; diff --git a/src/libstd/num/i32.rs b/src/libstd/num/i32.rs index 0526f2c488b..69d4b0639f7 100644 --- a/src/libstd/num/i32.rs +++ b/src/libstd/num/i32.rs @@ -10,7 +10,7 @@ //! Operations and constants for signed 32-bits integers (`i32` type) -#[allow(non_uppercase_statics)]; +#![allow(non_uppercase_statics)] use prelude::*; diff --git a/src/libstd/num/i64.rs b/src/libstd/num/i64.rs index 0c1c01dbf4a..1f7066c25db 100644 --- a/src/libstd/num/i64.rs +++ b/src/libstd/num/i64.rs @@ -10,7 +10,7 @@ //! Operations and constants for signed 64-bits integers (`i64` type) -#[allow(non_uppercase_statics)]; +#![allow(non_uppercase_statics)] use prelude::*; diff --git a/src/libstd/num/i8.rs b/src/libstd/num/i8.rs index 881cc46201e..061ffddf231 100644 --- a/src/libstd/num/i8.rs +++ b/src/libstd/num/i8.rs @@ -10,7 +10,7 @@ //! Operations and constants for signed 8-bits integers (`i8` type) -#[allow(non_uppercase_statics)]; +#![allow(non_uppercase_statics)] use prelude::*; diff --git a/src/libstd/num/int.rs b/src/libstd/num/int.rs index 83c9e8ea855..66b204ee8bd 100644 --- a/src/libstd/num/int.rs +++ b/src/libstd/num/int.rs @@ -10,7 +10,7 @@ //! Operations and constants for architecture-sized signed integers (`int` type) -#[allow(non_uppercase_statics)]; +#![allow(non_uppercase_statics)] use prelude::*; diff --git a/src/libstd/num/int_macros.rs b/src/libstd/num/int_macros.rs index ea62a3ec374..1d2c38f22bb 100644 --- a/src/libstd/num/int_macros.rs +++ b/src/libstd/num/int_macros.rs @@ -8,8 +8,8 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -#[macro_escape]; -#[doc(hidden)]; +#![macro_escape] +#![doc(hidden)] macro_rules! int_module (($T:ty, $bits:expr) => ( diff --git a/src/libstd/num/mod.rs b/src/libstd/num/mod.rs index d09cf28357b..feff0e7e6c0 100644 --- a/src/libstd/num/mod.rs +++ b/src/libstd/num/mod.rs @@ -13,7 +13,7 @@ //! These are implemented for the primitive numeric types in `std::{u8, u16, //! u32, u64, uint, i8, i16, i32, i64, int, f32, f64, float}`. -#[allow(missing_doc)]; +#![allow(missing_doc)] use clone::Clone; use cmp::{Eq, Ord}; diff --git a/src/libstd/num/strconv.rs b/src/libstd/num/strconv.rs index 9f9a9ec8e2e..dc49da415a4 100644 --- a/src/libstd/num/strconv.rs +++ b/src/libstd/num/strconv.rs @@ -8,7 +8,7 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -#[allow(missing_doc)]; +#![allow(missing_doc)] use clone::Clone; use container::Container; diff --git a/src/libstd/num/u16.rs b/src/libstd/num/u16.rs index d1de1ff0a72..ca473e9517e 100644 --- a/src/libstd/num/u16.rs +++ b/src/libstd/num/u16.rs @@ -10,7 +10,7 @@ //! Operations and constants for unsigned 16-bits integers (`u16` type) -#[allow(non_uppercase_statics)]; +#![allow(non_uppercase_statics)] use prelude::*; diff --git a/src/libstd/num/u32.rs b/src/libstd/num/u32.rs index 1caec678025..2a0b9aac667 100644 --- a/src/libstd/num/u32.rs +++ b/src/libstd/num/u32.rs @@ -10,7 +10,7 @@ //! Operations and constants for unsigned 32-bits integers (`u32` type) -#[allow(non_uppercase_statics)]; +#![allow(non_uppercase_statics)] use prelude::*; diff --git a/src/libstd/num/u64.rs b/src/libstd/num/u64.rs index ab495834eaa..2cfc5da95e8 100644 --- a/src/libstd/num/u64.rs +++ b/src/libstd/num/u64.rs @@ -10,7 +10,7 @@ //! Operations and constants for unsigned 64-bits integer (`u64` type) -#[allow(non_uppercase_statics)]; +#![allow(non_uppercase_statics)] use prelude::*; diff --git a/src/libstd/num/u8.rs b/src/libstd/num/u8.rs index a0ef574f6cf..30ed13a5952 100644 --- a/src/libstd/num/u8.rs +++ b/src/libstd/num/u8.rs @@ -10,7 +10,7 @@ //! Operations and constants for unsigned 8-bits integers (`u8` type) -#[allow(non_uppercase_statics)]; +#![allow(non_uppercase_statics)] use prelude::*; diff --git a/src/libstd/num/uint.rs b/src/libstd/num/uint.rs index 95d4a3a50be..6751fdb5d25 100644 --- a/src/libstd/num/uint.rs +++ b/src/libstd/num/uint.rs @@ -10,7 +10,7 @@ //! Operations and constants for architecture-sized unsigned integers (`uint` type) -#[allow(non_uppercase_statics)]; +#![allow(non_uppercase_statics)] use prelude::*; diff --git a/src/libstd/num/uint_macros.rs b/src/libstd/num/uint_macros.rs index 719afeb7878..ece30e72e06 100644 --- a/src/libstd/num/uint_macros.rs +++ b/src/libstd/num/uint_macros.rs @@ -8,8 +8,8 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -#[macro_escape]; -#[doc(hidden)]; +#![macro_escape] +#![doc(hidden)] macro_rules! uint_module (($T:ty, $T_SIGNED:ty, $bits:expr) => ( diff --git a/src/libstd/os.rs b/src/libstd/os.rs index eeebede6c58..b84ba6a501c 100644 --- a/src/libstd/os.rs +++ b/src/libstd/os.rs @@ -26,7 +26,7 @@ * to write OS-ignorant code by default. */ -#[allow(missing_doc)]; +#![allow(missing_doc)] #[cfg(target_os = "macos")] #[cfg(windows)] diff --git a/src/libstd/path/windows.rs b/src/libstd/path/windows.rs index d488997b0c2..a641787dfd1 100644 --- a/src/libstd/path/windows.rs +++ b/src/libstd/path/windows.rs @@ -637,7 +637,7 @@ impl Path { /// See str_components() for details. pub fn components<'a>(&'a self) -> Components<'a> { fn convert<'a>(x: Option<&'a str>) -> &'a [u8] { - #[inline]; + #![inline] x.unwrap().as_bytes() } self.str_components().map(convert) @@ -647,7 +647,7 @@ impl Path { /// See str_components() for details. pub fn rev_components<'a>(&'a self) -> RevComponents<'a> { fn convert<'a>(x: Option<&'a str>) -> &'a [u8] { - #[inline]; + #![inline] x.unwrap().as_bytes() } self.rev_str_components().map(convert) diff --git a/src/libstd/raw.rs b/src/libstd/raw.rs index 94ad268f512..d776b05bcd9 100644 --- a/src/libstd/raw.rs +++ b/src/libstd/raw.rs @@ -8,7 +8,7 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -#[allow(missing_doc)]; +#![allow(missing_doc)] //! Contains struct definitions for the layout of compiler built-in types. //! diff --git a/src/libstd/reflect.rs b/src/libstd/reflect.rs index a9e70bd3c63..183318cbfdb 100644 --- a/src/libstd/reflect.rs +++ b/src/libstd/reflect.rs @@ -14,7 +14,7 @@ Runtime type reflection */ -#[allow(missing_doc)]; +#![allow(missing_doc)] use intrinsics::{Disr, Opaque, TyDesc, TyVisitor}; use mem; diff --git a/src/libstd/repr.rs b/src/libstd/repr.rs index 675250a2710..e15ca3c0320 100644 --- a/src/libstd/repr.rs +++ b/src/libstd/repr.rs @@ -14,7 +14,7 @@ More runtime type reflection */ -#[allow(missing_doc)]; +#![allow(missing_doc)] use cast::transmute; use char; diff --git a/src/libstd/rt/backtrace.rs b/src/libstd/rt/backtrace.rs index 7ae2521c423..96f95622b92 100644 --- a/src/libstd/rt/backtrace.rs +++ b/src/libstd/rt/backtrace.rs @@ -8,7 +8,7 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -#[allow(non_camel_case_types)]; +#![allow(non_camel_case_types)] use char::Char; use container::Container; diff --git a/src/libstd/rt/bookkeeping.rs b/src/libstd/rt/bookkeeping.rs index 932cd7af033..9e772d8ad23 100644 --- a/src/libstd/rt/bookkeeping.rs +++ b/src/libstd/rt/bookkeeping.rs @@ -18,8 +18,8 @@ //! each respective runtime to make sure that they call increment() and //! decrement() manually. -#[experimental]; // this is a massive code smell -#[doc(hidden)]; +#![experimental] // this is a massive code smell +#![doc(hidden)] use sync::atomics; use unstable::mutex::{StaticNativeMutex, NATIVE_MUTEX_INIT}; diff --git a/src/libstd/rt/libunwind.rs b/src/libstd/rt/libunwind.rs index fabfa2c8a7a..e9a925fb897 100644 --- a/src/libstd/rt/libunwind.rs +++ b/src/libstd/rt/libunwind.rs @@ -10,8 +10,8 @@ //! Unwind library interface -#[allow(non_camel_case_types)]; -#[allow(dead_code)]; // these are just bindings +#![allow(non_camel_case_types)] +#![allow(dead_code)] // these are just bindings use libc; diff --git a/src/libstd/rt/local_ptr.rs b/src/libstd/rt/local_ptr.rs index 898004c665d..30068712977 100644 --- a/src/libstd/rt/local_ptr.rs +++ b/src/libstd/rt/local_ptr.rs @@ -15,7 +15,7 @@ //! XXX: Add runtime checks for usage of inconsistent pointer types. //! and for overwriting an existing pointer. -#[allow(dead_code)]; +#![allow(dead_code)] use cast; use ops::Drop; diff --git a/src/libstd/rt/macros.rs b/src/libstd/rt/macros.rs index 3ef57710344..74675c85b96 100644 --- a/src/libstd/rt/macros.rs +++ b/src/libstd/rt/macros.rs @@ -13,7 +13,7 @@ //! These macros call functions which are only accessible in the `rt` module, so //! they aren't defined anywhere outside of the `rt` module. -#[macro_escape]; +#![macro_escape] macro_rules! rterrln ( ($($arg:tt)*) => ( { diff --git a/src/libstd/rt/mod.rs b/src/libstd/rt/mod.rs index 28f11f44054..5e2f8efd2e3 100644 --- a/src/libstd/rt/mod.rs +++ b/src/libstd/rt/mod.rs @@ -52,7 +52,7 @@ Several modules in `core` are clients of `rt`: */ // FIXME: this should not be here. -#[allow(missing_doc)]; +#![allow(missing_doc)] use any::Any; use kinds::Send; diff --git a/src/libstd/rt/thread.rs b/src/libstd/rt/thread.rs index 7c4bd895469..1802016e3b3 100644 --- a/src/libstd/rt/thread.rs +++ b/src/libstd/rt/thread.rs @@ -14,7 +14,7 @@ //! These functions operate outside of the rust runtime, creating threads //! which are not used for scheduling in any way. -#[allow(non_camel_case_types)]; +#![allow(non_camel_case_types)] use cast; use kinds::Send; diff --git a/src/libstd/rt/thread_local_storage.rs b/src/libstd/rt/thread_local_storage.rs index 40d9523cf3a..2f567e91b4c 100644 --- a/src/libstd/rt/thread_local_storage.rs +++ b/src/libstd/rt/thread_local_storage.rs @@ -8,7 +8,7 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -#[allow(dead_code)]; +#![allow(dead_code)] #[cfg(unix)] use libc::c_int; diff --git a/src/libstd/slice.rs b/src/libstd/slice.rs index 8602c653523..b5055dfe8b3 100644 --- a/src/libstd/slice.rs +++ b/src/libstd/slice.rs @@ -99,7 +99,7 @@ There are a number of free functions that create or take vectors, for example: */ -#[warn(non_camel_case_types)]; +#![warn(non_camel_case_types)] use cast; use cast::transmute; diff --git a/src/libstd/str.rs b/src/libstd/str.rs index fac4202217f..0e640d3a662 100644 --- a/src/libstd/str.rs +++ b/src/libstd/str.rs @@ -4008,7 +4008,7 @@ mod tests { #[test] fn test_add() { - #[allow(unnecessary_allocation)]; + #![allow(unnecessary_allocation)] macro_rules! t ( ($s1:expr, $s2:expr, $e:expr) => { { let s1 = $s1; diff --git a/src/libstd/sync/atomics.rs b/src/libstd/sync/atomics.rs index bca7cf25944..6cc2f85bd95 100644 --- a/src/libstd/sync/atomics.rs +++ b/src/libstd/sync/atomics.rs @@ -105,7 +105,7 @@ //! } //! ``` -#[allow(missing_doc)]; +#![allow(missing_doc)] use intrinsics; use cast; diff --git a/src/libstd/sync/mpmc_bounded_queue.rs b/src/libstd/sync/mpmc_bounded_queue.rs index 95f592baff0..dfa962cdb80 100644 --- a/src/libstd/sync/mpmc_bounded_queue.rs +++ b/src/libstd/sync/mpmc_bounded_queue.rs @@ -25,7 +25,7 @@ * policies, either expressed or implied, of Dmitry Vyukov. */ -#[allow(missing_doc, dead_code)]; +#![allow(missing_doc, dead_code)] // http://www.1024cores.net/home/lock-free-algorithms/queues/bounded-mpmc-queue diff --git a/src/libstd/tuple.rs b/src/libstd/tuple.rs index c4ce6b5ae66..732b006b245 100644 --- a/src/libstd/tuple.rs +++ b/src/libstd/tuple.rs @@ -10,7 +10,7 @@ //! Operations on tuples -#[allow(missing_doc)]; +#![allow(missing_doc)] use clone::Clone; #[cfg(not(test))] use cmp::*; diff --git a/src/libstd/unicode.rs b/src/libstd/unicode.rs index 645db8e040b..c98861a0fe7 100644 --- a/src/libstd/unicode.rs +++ b/src/libstd/unicode.rs @@ -10,8 +10,8 @@ // The following code was generated by "src/etc/unicode.py" -#[allow(missing_doc)]; -#[allow(non_uppercase_statics)]; +#![allow(missing_doc)] +#![allow(non_uppercase_statics)] fn bsearch_range_table(c: char, r: &'static [(char,char)]) -> bool { use cmp::{Equal, Less, Greater}; diff --git a/src/libstd/unstable/mod.rs b/src/libstd/unstable/mod.rs index 720bf011fa0..ddbf650e64a 100644 --- a/src/libstd/unstable/mod.rs +++ b/src/libstd/unstable/mod.rs @@ -8,7 +8,7 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -#[doc(hidden)]; +#![doc(hidden)] use prelude::*; use libc::uintptr_t; diff --git a/src/libstd/unstable/mutex.rs b/src/libstd/unstable/mutex.rs index 6f5ef067e89..eda2df487aa 100644 --- a/src/libstd/unstable/mutex.rs +++ b/src/libstd/unstable/mutex.rs @@ -56,7 +56,7 @@ //! } // `lock` is deallocated here //! ``` -#[allow(non_camel_case_types)]; +#![allow(non_camel_case_types)] use option::{Option, None, Some}; use ops::Drop; diff --git a/src/libstd/unstable/simd.rs b/src/libstd/unstable/simd.rs index 1029e5fdbd3..01200833b19 100644 --- a/src/libstd/unstable/simd.rs +++ b/src/libstd/unstable/simd.rs @@ -10,7 +10,7 @@ //! SIMD vectors -#[allow(non_camel_case_types)]; +#![allow(non_camel_case_types)] #[experimental] #[simd] |
