Use new attribute syntax in python files in src/etc too (#13478)
This commit is contained in:
parent
e2e754810c
commit
713e87526e
@ -37,7 +37,7 @@ TEMPLATE = """// Copyright {year} The Rust Project Developers. See the COPYRIGHT
|
||||
|
||||
// This file was auto-generated using 'src/etc/generate-keyword-span-tests.py'
|
||||
|
||||
#[feature(struct_variant)];
|
||||
#![feature(struct_variant)]
|
||||
extern crate rand;
|
||||
|
||||
{error_deriving}
|
||||
|
@ -411,8 +411,8 @@ rf.write('''// Copyright 2012-2013 The Rust Project Developers. See the COPYRIGH
|
||||
|
||||
// The following code was generated by "src/etc/unicode.py"
|
||||
|
||||
#[allow(missing_doc)];
|
||||
#[allow(non_uppercase_statics)];
|
||||
#![allow(missing_doc)]
|
||||
#![allow(non_uppercase_statics)]
|
||||
|
||||
''')
|
||||
|
||||
|
@ -126,7 +126,7 @@ impl<'a> fold::Folder for PreludeInjector<'a> {
|
||||
fn fold_crate(&mut self, krate: ast::Crate) -> ast::Crate {
|
||||
if !no_prelude(krate.attrs.as_slice()) {
|
||||
// only add `use std::prelude::*;` if there wasn't a
|
||||
// `#[no_implicit_prelude];` at the crate level.
|
||||
// `#![no_implicit_prelude]` at the crate level.
|
||||
ast::Crate {
|
||||
module: self.fold_mod(&krate.module),
|
||||
..krate
|
||||
@ -138,7 +138,7 @@ impl<'a> fold::Folder for PreludeInjector<'a> {
|
||||
|
||||
fn fold_item(&mut self, item: @ast::Item) -> SmallVector<@ast::Item> {
|
||||
if !no_prelude(item.attrs.as_slice()) {
|
||||
// only recur if there wasn't `#[no_implicit_prelude];`
|
||||
// only recur if there wasn't `#![no_implicit_prelude]`
|
||||
// on this item, i.e. this means that the prelude is not
|
||||
// implicitly imported though the whole subtree
|
||||
fold::noop_fold_item(item, self)
|
||||
|
@ -8,7 +8,7 @@
|
||||
// option. This file may not be copied, modified, or distributed
|
||||
// except according to those terms.
|
||||
|
||||
// #[warn(deprecated_mode)];
|
||||
// #![warn(deprecated_mode)]
|
||||
|
||||
use middle::ty;
|
||||
use middle::ty_fold;
|
||||
|
@ -250,7 +250,7 @@ strings and instead directly write the output. Under the hood, this function is
|
||||
actually invoking the `write` function defined in this module. Example usage is:
|
||||
|
||||
```rust
|
||||
# #[allow(unused_must_use)];
|
||||
# #![allow(unused_must_use)]
|
||||
use std::io;
|
||||
|
||||
let mut w = io::MemWriter::new();
|
||||
@ -699,7 +699,7 @@ uniform_fn_call_workaround! {
|
||||
/// # Example
|
||||
///
|
||||
/// ```rust
|
||||
/// # #[allow(unused_must_use)];
|
||||
/// # #![allow(unused_must_use)]
|
||||
/// use std::fmt;
|
||||
/// use std::io;
|
||||
///
|
||||
|
@ -125,7 +125,7 @@ impl<R: Reader> Reader for BufferedReader<R> {
|
||||
/// # Example
|
||||
///
|
||||
/// ```rust
|
||||
/// # #[allow(unused_must_use)];
|
||||
/// # #![allow(unused_must_use)]
|
||||
/// use std::io::{BufferedWriter, File};
|
||||
///
|
||||
/// let file = File::open(&Path::new("message.txt"));
|
||||
@ -287,7 +287,7 @@ impl<W: Reader> Reader for InternalBufferedWriter<W> {
|
||||
/// # Example
|
||||
///
|
||||
/// ```rust
|
||||
/// # #[allow(unused_must_use)];
|
||||
/// # #![allow(unused_must_use)]
|
||||
/// use std::io::{BufferedStream, File};
|
||||
///
|
||||
/// let file = File::open(&Path::new("message.txt"));
|
||||
|
@ -89,7 +89,7 @@ impl Reader for ChanReader {
|
||||
/// # Example
|
||||
///
|
||||
/// ```
|
||||
/// # #[allow(unused_must_use)];
|
||||
/// # #![allow(unused_must_use)]
|
||||
/// use std::io::ChanWriter;
|
||||
///
|
||||
/// let (tx, rx) = channel();
|
||||
|
@ -28,7 +28,7 @@ particular bits of it, etc.
|
||||
# Example
|
||||
|
||||
```rust
|
||||
# #[allow(unused_must_use)];
|
||||
# #![allow(unused_must_use)]
|
||||
use std::io::{File, fs};
|
||||
|
||||
let path = Path::new("foo.txt");
|
||||
@ -162,7 +162,7 @@ impl File {
|
||||
/// # Example
|
||||
///
|
||||
/// ```rust
|
||||
/// # #[allow(unused_must_use)];
|
||||
/// # #![allow(unused_must_use)]
|
||||
/// use std::io::File;
|
||||
///
|
||||
/// let mut f = File::create(&Path::new("foo.txt"));
|
||||
@ -220,7 +220,7 @@ impl File {
|
||||
/// # Example
|
||||
///
|
||||
/// ```rust
|
||||
/// # #[allow(unused_must_use)];
|
||||
/// # #![allow(unused_must_use)]
|
||||
/// use std::io::fs;
|
||||
///
|
||||
/// let p = Path::new("/some/file/path.txt");
|
||||
@ -290,7 +290,7 @@ pub fn lstat(path: &Path) -> IoResult<FileStat> {
|
||||
/// # Example
|
||||
///
|
||||
/// ```rust
|
||||
/// # #[allow(unused_must_use)];
|
||||
/// # #![allow(unused_must_use)]
|
||||
/// use std::io::fs;
|
||||
///
|
||||
/// fs::rename(&Path::new("foo"), &Path::new("bar"));
|
||||
@ -314,7 +314,7 @@ pub fn rename(from: &Path, to: &Path) -> IoResult<()> {
|
||||
/// # Example
|
||||
///
|
||||
/// ```rust
|
||||
/// # #[allow(unused_must_use)];
|
||||
/// # #![allow(unused_must_use)]
|
||||
/// use std::io::fs;
|
||||
///
|
||||
/// fs::copy(&Path::new("foo.txt"), &Path::new("bar.txt"));
|
||||
@ -364,7 +364,7 @@ pub fn copy(from: &Path, to: &Path) -> IoResult<()> {
|
||||
/// # Example
|
||||
///
|
||||
/// ```rust
|
||||
/// # #[allow(unused_must_use)];
|
||||
/// # #![allow(unused_must_use)]
|
||||
/// use std::io;
|
||||
/// use std::io::fs;
|
||||
///
|
||||
@ -416,7 +416,7 @@ pub fn readlink(path: &Path) -> IoResult<Path> {
|
||||
/// # Example
|
||||
///
|
||||
/// ```rust
|
||||
/// # #[allow(unused_must_use)];
|
||||
/// # #![allow(unused_must_use)]
|
||||
/// use std::io;
|
||||
/// use std::io::fs;
|
||||
///
|
||||
@ -437,7 +437,7 @@ pub fn mkdir(path: &Path, mode: FilePermission) -> IoResult<()> {
|
||||
/// # Example
|
||||
///
|
||||
/// ```rust
|
||||
/// # #[allow(unused_must_use)];
|
||||
/// # #![allow(unused_must_use)]
|
||||
/// use std::io::fs;
|
||||
///
|
||||
/// let p = Path::new("/some/dir");
|
||||
|
@ -44,7 +44,7 @@ fn combine(seek: SeekStyle, cur: uint, end: uint, offset: i64) -> IoResult<u64>
|
||||
/// # Example
|
||||
///
|
||||
/// ```rust
|
||||
/// # #[allow(unused_must_use)];
|
||||
/// # #![allow(unused_must_use)]
|
||||
/// use std::io::MemWriter;
|
||||
///
|
||||
/// let mut w = MemWriter::new();
|
||||
@ -125,7 +125,7 @@ impl Seek for MemWriter {
|
||||
/// # Example
|
||||
///
|
||||
/// ```rust
|
||||
/// # #[allow(unused_must_use)];
|
||||
/// # #![allow(unused_must_use)]
|
||||
/// use std::io::MemReader;
|
||||
///
|
||||
/// let mut r = MemReader::new(vec!(0, 1, 2));
|
||||
@ -209,7 +209,7 @@ impl Buffer for MemReader {
|
||||
/// # Example
|
||||
///
|
||||
/// ```rust
|
||||
/// # #[allow(unused_must_use)];
|
||||
/// # #![allow(unused_must_use)]
|
||||
/// use std::io::BufWriter;
|
||||
///
|
||||
/// let mut buf = [0, ..4];
|
||||
@ -267,7 +267,7 @@ impl<'a> Seek for BufWriter<'a> {
|
||||
/// # Example
|
||||
///
|
||||
/// ```rust
|
||||
/// # #[allow(unused_must_use)];
|
||||
/// # #![allow(unused_must_use)]
|
||||
/// use std::io::BufReader;
|
||||
///
|
||||
/// let mut buf = [0, 1, 2, 3];
|
||||
|
@ -46,7 +46,7 @@ Some examples of obvious things you might want to do
|
||||
* Write a line to a file
|
||||
|
||||
```rust
|
||||
# #[allow(unused_must_use)];
|
||||
# #![allow(unused_must_use)]
|
||||
use std::io::File;
|
||||
|
||||
let mut file = File::create(&Path::new("message.txt"));
|
||||
@ -82,7 +82,7 @@ Some examples of obvious things you might want to do
|
||||
* Make a simple TCP client connection and request
|
||||
|
||||
```rust,should_fail
|
||||
# #[allow(unused_must_use)];
|
||||
# #![allow(unused_must_use)]
|
||||
use std::io::net::ip::SocketAddr;
|
||||
use std::io::net::tcp::TcpStream;
|
||||
|
||||
@ -159,7 +159,7 @@ be an error.
|
||||
If you wanted to handle the error though you might write:
|
||||
|
||||
```rust
|
||||
# #[allow(unused_must_use)];
|
||||
# #![allow(unused_must_use)]
|
||||
use std::io::File;
|
||||
|
||||
match File::create(&Path::new("diary.txt")).write(bytes!("Met a girl.\n")) {
|
||||
|
@ -31,7 +31,7 @@ use rt::rtio::{RtioTcpAcceptor, RtioTcpStream};
|
||||
/// # Example
|
||||
///
|
||||
/// ```rust
|
||||
/// # #[allow(unused_must_use)];
|
||||
/// # #![allow(unused_must_use)]
|
||||
/// use std::io::net::tcp::TcpStream;
|
||||
/// use std::io::net::ip::{Ipv4Addr, SocketAddr};
|
||||
///
|
||||
|
@ -31,7 +31,7 @@ use rt::rtio::{RtioSocket, RtioUdpSocket, IoFactory, LocalIo};
|
||||
/// # Example
|
||||
///
|
||||
/// ```rust,no_run
|
||||
/// # #[allow(unused_must_use)];
|
||||
/// # #![allow(unused_must_use)]
|
||||
/// use std::io::net::udp::UdpSocket;
|
||||
/// use std::io::net::ip::{Ipv4Addr, SocketAddr};
|
||||
///
|
||||
|
@ -52,7 +52,7 @@ impl UnixStream {
|
||||
/// # Example
|
||||
///
|
||||
/// ```rust
|
||||
/// # #[allow(unused_must_use)];
|
||||
/// # #![allow(unused_must_use)]
|
||||
/// use std::io::net::unix::UnixStream;
|
||||
///
|
||||
/// let server = Path::new("path/to/my/socket");
|
||||
@ -98,7 +98,7 @@ impl UnixListener {
|
||||
/// ```
|
||||
/// # fn main() {}
|
||||
/// # fn foo() {
|
||||
/// # #[allow(unused_must_use)];
|
||||
/// # #![allow(unused_must_use)]
|
||||
/// use std::io::net::unix::UnixListener;
|
||||
/// use std::io::{Listener, Acceptor};
|
||||
///
|
||||
|
@ -37,7 +37,7 @@ impl PipeStream {
|
||||
/// # Example
|
||||
///
|
||||
/// ```rust
|
||||
/// # #[allow(unused_must_use)];
|
||||
/// # #![allow(unused_must_use)]
|
||||
/// extern crate libc;
|
||||
///
|
||||
/// use std::io::pipe::PipeStream;
|
||||
|
@ -18,7 +18,7 @@ about the stream or terminal to which it is attached.
|
||||
# Example
|
||||
|
||||
```rust
|
||||
# #[allow(unused_must_use)];
|
||||
# #![allow(unused_must_use)]
|
||||
use std::io;
|
||||
|
||||
let mut out = io::stdout();
|
||||
|
@ -29,7 +29,7 @@
|
||||
/// # Example
|
||||
///
|
||||
/// ```should_fail
|
||||
/// # #[allow(unreachable_code)];
|
||||
/// # #![allow(unreachable_code)]
|
||||
/// fail!();
|
||||
/// fail!("this is a terrible mistake!");
|
||||
/// fail!(4); // fail with the value of 4 to be collected elsewhere
|
||||
@ -188,7 +188,7 @@ macro_rules! format(
|
||||
/// # Example
|
||||
///
|
||||
/// ```
|
||||
/// # #[allow(unused_must_use)];
|
||||
/// # #![allow(unused_must_use)]
|
||||
/// use std::io::MemWriter;
|
||||
///
|
||||
/// let mut w = MemWriter::new();
|
||||
|
@ -8,7 +8,7 @@
|
||||
// option. This file may not be copied, modified, or distributed
|
||||
// except according to those terms.
|
||||
|
||||
#[crate_id="anonexternmod#0.1"];
|
||||
#![crate_id="anonexternmod#0.1"]
|
||||
|
||||
extern crate libc;
|
||||
|
||||
|
@ -8,7 +8,7 @@
|
||||
// option. This file may not be copied, modified, or distributed
|
||||
// except according to those terms.
|
||||
|
||||
#[crate_id="cci_impl_lib"];
|
||||
#![crate_id="cci_impl_lib"]
|
||||
|
||||
pub trait uint_helpers {
|
||||
fn to(&self, v: uint, f: |uint|);
|
||||
|
@ -8,7 +8,7 @@
|
||||
// option. This file may not be copied, modified, or distributed
|
||||
// except according to those terms.
|
||||
|
||||
#[crate_id="cci_iter_lib"];
|
||||
#![crate_id="cci_iter_lib"]
|
||||
|
||||
#[inline]
|
||||
pub fn iter<T>(v: &[T], f: |&T|) {
|
||||
|
@ -8,7 +8,7 @@
|
||||
// option. This file may not be copied, modified, or distributed
|
||||
// except according to those terms.
|
||||
|
||||
#[feature(managed_boxes)];
|
||||
#![feature(managed_boxes)]
|
||||
|
||||
use std::cell::RefCell;
|
||||
|
||||
|
@ -8,7 +8,7 @@
|
||||
// option. This file may not be copied, modified, or distributed
|
||||
// except according to those terms.
|
||||
|
||||
#[crate_id="cci_no_inline_lib"];
|
||||
#![crate_id="cci_no_inline_lib"]
|
||||
|
||||
|
||||
// same as cci_iter_lib, more-or-less, but not marked inline
|
||||
|
@ -8,6 +8,6 @@
|
||||
// option. This file may not be copied, modified, or distributed
|
||||
// except according to those terms.
|
||||
|
||||
#[crate_id = "a"];
|
||||
#![crate_id = "a"]
|
||||
|
||||
pub fn foo<T>() {}
|
||||
|
@ -8,7 +8,7 @@
|
||||
// option. This file may not be copied, modified, or distributed
|
||||
// except according to those terms.
|
||||
|
||||
#[crate_id = "a"];
|
||||
#![crate_id = "a"]
|
||||
|
||||
pub fn foo<T>() { println!("hello!"); }
|
||||
|
||||
|
@ -8,7 +8,7 @@
|
||||
// option. This file may not be copied, modified, or distributed
|
||||
// except according to those terms.
|
||||
|
||||
#[crate_id = "b"];
|
||||
#![crate_id = "b"]
|
||||
|
||||
extern crate a;
|
||||
|
||||
|
@ -8,8 +8,8 @@
|
||||
// option. This file may not be copied, modified, or distributed
|
||||
// except according to those terms.
|
||||
|
||||
#[feature(managed_boxes)];
|
||||
#[crate_id="crate_method_reexport_grrrrrrr2"];
|
||||
#![feature(managed_boxes)]
|
||||
#![crate_id="crate_method_reexport_grrrrrrr2"]
|
||||
|
||||
pub use name_pool::add;
|
||||
|
||||
|
@ -8,8 +8,8 @@
|
||||
// option. This file may not be copied, modified, or distributed
|
||||
// except according to those terms.
|
||||
|
||||
#[crate_id="crateresolve1#0.1"];
|
||||
#![crate_id="crateresolve1#0.1"]
|
||||
|
||||
#[crate_type = "lib"];
|
||||
#![crate_type = "lib"]
|
||||
|
||||
pub fn f() -> int { 10 }
|
||||
|
@ -8,8 +8,8 @@
|
||||
// option. This file may not be copied, modified, or distributed
|
||||
// except according to those terms.
|
||||
|
||||
#[crate_id="crateresolve1#0.2"];
|
||||
#![crate_id="crateresolve1#0.2"]
|
||||
|
||||
#[crate_type = "lib"];
|
||||
#![crate_type = "lib"]
|
||||
|
||||
pub fn f() -> int { 20 }
|
||||
|
@ -8,8 +8,8 @@
|
||||
// option. This file may not be copied, modified, or distributed
|
||||
// except according to those terms.
|
||||
|
||||
#[crate_id="crateresolve1#0.3"];
|
||||
#![crate_id="crateresolve1#0.3"]
|
||||
|
||||
#[crate_type = "lib"];
|
||||
#![crate_type = "lib"]
|
||||
|
||||
pub fn f() -> int { 30 }
|
||||
|
@ -8,8 +8,8 @@
|
||||
// option. This file may not be copied, modified, or distributed
|
||||
// except according to those terms.
|
||||
|
||||
#[crate_id="crateresolve2#0.1"];
|
||||
#![crate_id="crateresolve2#0.1"]
|
||||
|
||||
#[crate_type = "lib"];
|
||||
#![crate_type = "lib"]
|
||||
|
||||
pub fn f() -> int { 10 }
|
||||
|
@ -8,8 +8,8 @@
|
||||
// option. This file may not be copied, modified, or distributed
|
||||
// except according to those terms.
|
||||
|
||||
#[crate_id="crateresolve2#0.2"];
|
||||
#![crate_id="crateresolve2#0.2"]
|
||||
|
||||
#[crate_type = "lib"];
|
||||
#![crate_type = "lib"]
|
||||
|
||||
pub fn f() -> int { 20 }
|
||||
|
@ -8,8 +8,8 @@
|
||||
// option. This file may not be copied, modified, or distributed
|
||||
// except according to those terms.
|
||||
|
||||
#[crate_id="crateresolve2#0.3"];
|
||||
#![crate_id="crateresolve2#0.3"]
|
||||
|
||||
#[crate_type = "lib"];
|
||||
#![crate_type = "lib"]
|
||||
|
||||
pub fn f() -> int { 30 }
|
||||
|
@ -8,8 +8,8 @@
|
||||
// option. This file may not be copied, modified, or distributed
|
||||
// except according to those terms.
|
||||
|
||||
#[crate_id="crateresolve3#0.1"];
|
||||
#![crate_id="crateresolve3#0.1"]
|
||||
|
||||
#[crate_type = "lib"];
|
||||
#![crate_type = "lib"]
|
||||
|
||||
pub fn f() -> int { 10 }
|
||||
|
@ -8,8 +8,8 @@
|
||||
// option. This file may not be copied, modified, or distributed
|
||||
// except according to those terms.
|
||||
|
||||
#[crate_id="crateresolve3#0.2"];
|
||||
#![crate_id="crateresolve3#0.2"]
|
||||
|
||||
#[crate_type = "lib"];
|
||||
#![crate_type = "lib"]
|
||||
|
||||
pub fn g() -> int { 20 }
|
||||
|
@ -8,7 +8,7 @@
|
||||
// option. This file may not be copied, modified, or distributed
|
||||
// except according to those terms.
|
||||
|
||||
#[crate_id="crateresolve4a#0.1"];
|
||||
#[crate_type = "lib"];
|
||||
#![crate_id="crateresolve4a#0.1"]
|
||||
#![crate_type = "lib"]
|
||||
|
||||
pub fn f() -> int { 10 }
|
||||
|
@ -8,7 +8,7 @@
|
||||
// option. This file may not be copied, modified, or distributed
|
||||
// except according to those terms.
|
||||
|
||||
#[crate_id="crateresolve4a#0.2"];
|
||||
#[crate_type = "lib"];
|
||||
#![crate_id="crateresolve4a#0.2"]
|
||||
#![crate_type = "lib"]
|
||||
|
||||
pub fn g() -> int { 20 }
|
||||
|
@ -10,8 +10,8 @@
|
||||
|
||||
// aux-build:crateresolve4a-1.rs
|
||||
// aux-build:crateresolve4a-2.rs
|
||||
#[crate_id="crateresolve4b#0.1"];
|
||||
#[crate_type = "lib"];
|
||||
#![crate_id="crateresolve4b#0.1"]
|
||||
#![crate_type = "lib"]
|
||||
|
||||
extern crate crateresolve4a = "crateresolve4a#0.2";
|
||||
|
||||
|
@ -10,8 +10,8 @@
|
||||
|
||||
// aux-build:crateresolve4a-1.rs
|
||||
// aux-build:crateresolve4a-2.rs
|
||||
#[crate_id="crateresolve4b#0.2"];
|
||||
#[crate_type = "lib"];
|
||||
#![crate_id="crateresolve4b#0.2"]
|
||||
#![crate_type = "lib"]
|
||||
|
||||
extern crate crateresolve4a = "crateresolve4a#0.1";
|
||||
|
||||
|
@ -8,9 +8,9 @@
|
||||
// option. This file may not be copied, modified, or distributed
|
||||
// except according to those terms.
|
||||
|
||||
#[crate_id="crateresolve5#0.1"];
|
||||
#![crate_id="crateresolve5#0.1"]
|
||||
|
||||
#[crate_type = "lib"];
|
||||
#![crate_type = "lib"]
|
||||
|
||||
pub struct NameVal { pub name: ~str, pub val: int }
|
||||
|
||||
|
@ -8,9 +8,9 @@
|
||||
// option. This file may not be copied, modified, or distributed
|
||||
// except according to those terms.
|
||||
|
||||
#[crate_id="crateresolve5#0.2"];
|
||||
#![crate_id="crateresolve5#0.2"]
|
||||
|
||||
#[crate_type = "lib"];
|
||||
#![crate_type = "lib"]
|
||||
|
||||
pub struct NameVal { pub name: ~str, pub val: int }
|
||||
pub fn struct_nameval() -> NameVal {
|
||||
|
@ -9,8 +9,8 @@
|
||||
// except according to those terms.
|
||||
|
||||
// default link meta for 'package_id' will be equal to filestem
|
||||
#[crate_id="crateresolve8#0.1"];
|
||||
#![crate_id="crateresolve8#0.1"]
|
||||
|
||||
#[crate_type = "lib"];
|
||||
#![crate_type = "lib"]
|
||||
|
||||
pub fn f() -> int { 20 }
|
||||
|
@ -8,7 +8,7 @@
|
||||
// option. This file may not be copied, modified, or distributed
|
||||
// except according to those terms.
|
||||
|
||||
#[crate_id="crateresolve_calories#0.1"];
|
||||
#[crate_type = "lib"];
|
||||
#![crate_id="crateresolve_calories#0.1"]
|
||||
#![crate_type = "lib"]
|
||||
|
||||
pub fn f() -> int { 100 }
|
||||
|
@ -8,7 +8,7 @@
|
||||
// option. This file may not be copied, modified, or distributed
|
||||
// except according to those terms.
|
||||
|
||||
#[crate_id="crateresolve_calories#0.1"];
|
||||
#[crate_type = "lib"];
|
||||
#![crate_id="crateresolve_calories#0.1"]
|
||||
#![crate_type = "lib"]
|
||||
|
||||
pub fn f() -> int { 200 }
|
||||
|
@ -8,7 +8,7 @@
|
||||
// option. This file may not be copied, modified, or distributed
|
||||
// except according to those terms.
|
||||
|
||||
#[feature(default_type_params)];
|
||||
#![feature(default_type_params)]
|
||||
|
||||
pub struct Heap;
|
||||
|
||||
|
@ -8,8 +8,8 @@
|
||||
// option. This file may not be copied, modified, or distributed
|
||||
// except according to those terms.
|
||||
|
||||
#[crate_id="externcallback#0.1"];
|
||||
#[crate_type = "lib"];
|
||||
#![crate_id="externcallback#0.1"]
|
||||
#![crate_type = "lib"]
|
||||
|
||||
extern crate libc;
|
||||
|
||||
|
@ -8,7 +8,7 @@
|
||||
// option. This file may not be copied, modified, or distributed
|
||||
// except according to those terms.
|
||||
|
||||
#[crate_type="lib"];
|
||||
#![crate_type="lib"]
|
||||
|
||||
pub mod extern_mod_ordering_lib {
|
||||
pub fn f() {}
|
||||
|
@ -8,7 +8,7 @@
|
||||
// option. This file may not be copied, modified, or distributed
|
||||
// except according to those terms.
|
||||
|
||||
#[crate_id="foreign_lib"];
|
||||
#![crate_id="foreign_lib"]
|
||||
|
||||
pub mod rustrt {
|
||||
extern crate libc;
|
||||
|
@ -8,7 +8,7 @@
|
||||
// option. This file may not be copied, modified, or distributed
|
||||
// except according to those terms.
|
||||
|
||||
#[crate_type = "lib"];
|
||||
#![crate_type = "lib"]
|
||||
|
||||
pub struct Fish {
|
||||
pub x: int
|
||||
|
@ -8,7 +8,7 @@
|
||||
// option. This file may not be copied, modified, or distributed
|
||||
// except according to those terms.
|
||||
|
||||
#[crate_id="inline_dtor#0.1"];
|
||||
#![crate_id="inline_dtor#0.1"]
|
||||
|
||||
pub struct Foo;
|
||||
|
||||
|
@ -8,7 +8,7 @@
|
||||
// option. This file may not be copied, modified, or distributed
|
||||
// except according to those terms.
|
||||
|
||||
#[crate_id="issue6919_3#0.1"];
|
||||
#![crate_id="issue6919_3#0.1"]
|
||||
|
||||
// part of issue-6919.rs
|
||||
|
||||
|
@ -8,7 +8,7 @@
|
||||
// option. This file may not be copied, modified, or distributed
|
||||
// except according to those terms.
|
||||
|
||||
#[deny(dead_code)];
|
||||
#![deny(dead_code)]
|
||||
|
||||
mod inner {
|
||||
pub trait Trait {
|
||||
|
@ -10,5 +10,5 @@
|
||||
|
||||
// no-prefer-dynamic
|
||||
|
||||
#[crate_id = "collections#0.11-pre"];
|
||||
#[crate_type = "dylib"];
|
||||
#![crate_id = "collections#0.11-pre"]
|
||||
#![crate_type = "dylib"]
|
||||
|
@ -10,5 +10,5 @@
|
||||
|
||||
// no-prefer-dynamic
|
||||
|
||||
#[crate_id = "collections#0.11-pre"];
|
||||
#[crate_type = "rlib"];
|
||||
#![crate_id = "collections#0.11-pre"]
|
||||
#![crate_type = "rlib"]
|
||||
|
@ -10,4 +10,4 @@
|
||||
|
||||
// no-prefer-dynamic
|
||||
|
||||
#[crate_type = "dylib"];
|
||||
#![crate_type = "dylib"]
|
||||
|
@ -10,4 +10,4 @@
|
||||
|
||||
// no-prefer-dynamic
|
||||
|
||||
#[crate_type = "rlib"];
|
||||
#![crate_type = "rlib"]
|
||||
|
@ -8,8 +8,8 @@
|
||||
// option. This file may not be copied, modified, or distributed
|
||||
// except according to those terms.
|
||||
|
||||
#[crate_id="a"];
|
||||
#[crate_type = "lib"];
|
||||
#![crate_id="a"]
|
||||
#![crate_type = "lib"]
|
||||
|
||||
pub trait i<T> { }
|
||||
|
||||
|
@ -8,8 +8,8 @@
|
||||
// option. This file may not be copied, modified, or distributed
|
||||
// except according to those terms.
|
||||
|
||||
#[crate_id="a#0.1"];
|
||||
#[crate_type = "lib"];
|
||||
#![crate_id="a#0.1"]
|
||||
#![crate_type = "lib"]
|
||||
|
||||
type t1 = uint;
|
||||
|
||||
|
@ -9,7 +9,7 @@
|
||||
// except according to those terms.
|
||||
|
||||
|
||||
#[crate_id="b#0.1"];
|
||||
#[crate_type = "lib"];
|
||||
#![crate_id="b#0.1"]
|
||||
#![crate_type = "lib"]
|
||||
|
||||
extern crate a;
|
||||
|
@ -8,8 +8,8 @@
|
||||
// option. This file may not be copied, modified, or distributed
|
||||
// except according to those terms.
|
||||
|
||||
#[crate_id="issue_2526#0.2"];
|
||||
#[crate_type = "lib"];
|
||||
#![crate_id="issue_2526#0.2"]
|
||||
#![crate_type = "lib"]
|
||||
|
||||
struct arc_destruct<T> {
|
||||
_data: int,
|
||||
|
@ -8,9 +8,9 @@
|
||||
// option. This file may not be copied, modified, or distributed
|
||||
// except according to those terms.
|
||||
|
||||
#[feature(managed_boxes)];
|
||||
#[crate_id="req"];
|
||||
#[crate_type = "lib"];
|
||||
#![feature(managed_boxes)]
|
||||
#![crate_id="req"]
|
||||
#![crate_type = "lib"]
|
||||
|
||||
extern crate collections;
|
||||
|
||||
|
@ -8,8 +8,8 @@
|
||||
// option. This file may not be copied, modified, or distributed
|
||||
// except according to those terms.
|
||||
|
||||
#[crate_id="socketlib"];
|
||||
#[crate_type = "lib"];
|
||||
#![crate_id="socketlib"]
|
||||
#![crate_type = "lib"]
|
||||
|
||||
pub mod socket {
|
||||
extern crate libc;
|
||||
|
@ -8,8 +8,8 @@
|
||||
// option. This file may not be copied, modified, or distributed
|
||||
// except according to those terms.
|
||||
|
||||
#[crate_id="numeric#0.1"];
|
||||
#[crate_type = "lib"];
|
||||
#![crate_id="numeric#0.1"]
|
||||
#![crate_type = "lib"]
|
||||
|
||||
pub trait Trig<T> {
|
||||
fn sin(&self) -> T;
|
||||
|
@ -8,7 +8,7 @@
|
||||
// option. This file may not be copied, modified, or distributed
|
||||
// except according to those terms.
|
||||
|
||||
#[feature(managed_boxes)];
|
||||
#![feature(managed_boxes)]
|
||||
|
||||
extern crate collections;
|
||||
|
||||
|
@ -8,7 +8,7 @@
|
||||
// option. This file may not be copied, modified, or distributed
|
||||
// except according to those terms.
|
||||
|
||||
#[feature(struct_variant)];
|
||||
#![feature(struct_variant)]
|
||||
|
||||
pub struct BTree<V> {
|
||||
pub node: TreeItem<V>,
|
||||
|
@ -8,7 +8,7 @@
|
||||
// option. This file may not be copied, modified, or distributed
|
||||
// except according to those terms.
|
||||
|
||||
#[crate_type = "lib"];
|
||||
#![crate_type = "lib"]
|
||||
|
||||
pub enum maybe<T> { just(T), nothing }
|
||||
|
||||
|
@ -8,7 +8,7 @@
|
||||
// option. This file may not be copied, modified, or distributed
|
||||
// except according to those terms.
|
||||
|
||||
#[crate_type = "lib"];
|
||||
#![crate_type = "lib"]
|
||||
|
||||
extern crate issue2378a;
|
||||
|
||||
|
@ -8,8 +8,8 @@
|
||||
// option. This file may not be copied, modified, or distributed
|
||||
// except according to those terms.
|
||||
|
||||
#[crate_id="a#0.1"];
|
||||
#[crate_type = "lib"];
|
||||
#![crate_id="a#0.1"]
|
||||
#![crate_type = "lib"]
|
||||
|
||||
trait to_strz {
|
||||
fn to_strz() -> ~str;
|
||||
|
@ -8,8 +8,8 @@
|
||||
// option. This file may not be copied, modified, or distributed
|
||||
// except according to those terms.
|
||||
|
||||
#[crate_id="c#0.1"];
|
||||
#[crate_type = "lib"];
|
||||
#![crate_id="c#0.1"]
|
||||
#![crate_type = "lib"]
|
||||
|
||||
extern crate a;
|
||||
|
||||
|
@ -8,7 +8,7 @@
|
||||
// option. This file may not be copied, modified, or distributed
|
||||
// except according to those terms.
|
||||
|
||||
#[allow(unused_imports)];
|
||||
#![allow(unused_imports)]
|
||||
#![feature(globs)]
|
||||
|
||||
extern crate issue_2316_a;
|
||||
|
@ -8,6 +8,6 @@
|
||||
// option. This file may not be copied, modified, or distributed
|
||||
// except according to those terms.
|
||||
|
||||
#[crate_type = "lib"];
|
||||
#![crate_type = "lib"]
|
||||
|
||||
pub mod issue_3136_a;
|
||||
|
@ -8,9 +8,9 @@
|
||||
// option. This file may not be copied, modified, or distributed
|
||||
// except according to those terms.
|
||||
|
||||
#[crate_id="issue_3979_traits#0.1"];
|
||||
#![crate_id="issue_3979_traits#0.1"]
|
||||
|
||||
#[crate_type = "lib"];
|
||||
#![crate_type = "lib"]
|
||||
|
||||
pub trait Positioned {
|
||||
fn SetX(&mut self, int);
|
||||
|
@ -8,7 +8,7 @@
|
||||
// option. This file may not be copied, modified, or distributed
|
||||
// except according to those terms.
|
||||
|
||||
#[crate_type = "lib"];
|
||||
#![crate_type = "lib"]
|
||||
|
||||
pub trait X {
|
||||
fn x() {
|
||||
|
@ -13,7 +13,7 @@
|
||||
|
||||
// Tests that metadata serialization works for the `Copy` kind.
|
||||
|
||||
#[crate_type="lib"];
|
||||
#![crate_type="lib"]
|
||||
|
||||
pub fn f<T:Copy>() {}
|
||||
|
||||
|
@ -7,8 +7,8 @@
|
||||
// <LICENSE-MIT or http://opensource.org/licenses/MIT>, at your
|
||||
// option. This file may not be copied, modified, or distributed
|
||||
// except according to those terms.
|
||||
#[crate_id="lint_stability#0.1"];
|
||||
#[crate_type = "lib"];
|
||||
#![crate_id="lint_stability#0.1"]
|
||||
#![crate_type = "lib"]
|
||||
|
||||
#[deprecated]
|
||||
pub fn deprecated() {}
|
||||
|
@ -8,7 +8,7 @@
|
||||
// option. This file may not be copied, modified, or distributed
|
||||
// except according to those terms.
|
||||
|
||||
#[feature(macro_rules)];
|
||||
#![feature(macro_rules)]
|
||||
|
||||
#[macro_export]
|
||||
macro_rules! make_a_5(
|
||||
|
@ -10,7 +10,7 @@
|
||||
|
||||
// force-host
|
||||
|
||||
#[feature(macro_registrar)];
|
||||
#![feature(macro_registrar)]
|
||||
|
||||
extern crate syntax;
|
||||
|
||||
|
@ -10,7 +10,7 @@
|
||||
|
||||
// force-host
|
||||
|
||||
#[feature(globs, macro_registrar, macro_rules, quote, managed_boxes)];
|
||||
#![feature(globs, macro_registrar, macro_rules, quote, managed_boxes)]
|
||||
|
||||
extern crate syntax;
|
||||
|
||||
|
@ -8,7 +8,7 @@
|
||||
// option. This file may not be copied, modified, or distributed
|
||||
// except according to those terms.
|
||||
|
||||
#[feature(macro_rules)];
|
||||
#![feature(macro_rules)]
|
||||
|
||||
pub mod inner {
|
||||
#[macro_export]
|
||||
|
@ -8,7 +8,7 @@
|
||||
// option. This file may not be copied, modified, or distributed
|
||||
// except according to those terms.
|
||||
|
||||
#[crate_type="lib"];
|
||||
#![crate_type="lib"]
|
||||
|
||||
pub struct S {
|
||||
x: int,
|
||||
|
@ -8,6 +8,6 @@
|
||||
// option. This file may not be copied, modified, or distributed
|
||||
// except according to those terms.
|
||||
|
||||
#[crate_type="lib"];
|
||||
#![crate_type="lib"]
|
||||
|
||||
pub struct Au(pub int);
|
||||
|
@ -8,6 +8,6 @@
|
||||
// option. This file may not be copied, modified, or distributed
|
||||
// except according to those terms.
|
||||
|
||||
#[no_std];
|
||||
#![no_std]
|
||||
|
||||
pub fn foo() {}
|
||||
|
@ -8,7 +8,7 @@
|
||||
// option. This file may not be copied, modified, or distributed
|
||||
// except according to those terms.
|
||||
|
||||
#[crate_id="static-function-pointer-aux"];
|
||||
#![crate_id="static-function-pointer-aux"]
|
||||
|
||||
pub fn f(x: int) -> int { -x }
|
||||
|
||||
|
@ -8,8 +8,8 @@
|
||||
// option. This file may not be copied, modified, or distributed
|
||||
// except according to those terms.
|
||||
|
||||
#[crate_id="static_methods_crate#0.1"];
|
||||
#[crate_type = "lib"];
|
||||
#![crate_id="static_methods_crate#0.1"]
|
||||
#![crate_type = "lib"]
|
||||
|
||||
use std::int;
|
||||
|
||||
|
@ -8,7 +8,7 @@
|
||||
// option. This file may not be copied, modified, or distributed
|
||||
// except according to those terms.
|
||||
|
||||
#[crate_type = "lib"];
|
||||
#![crate_type = "lib"]
|
||||
|
||||
static private: int = 0;
|
||||
pub static public: int = 0;
|
||||
|
@ -8,7 +8,7 @@
|
||||
// option. This file may not be copied, modified, or distributed
|
||||
// except according to those terms.
|
||||
|
||||
#[crate_type="lib"];
|
||||
#![crate_type="lib"]
|
||||
|
||||
pub struct S {
|
||||
pub x: int,
|
||||
|
@ -8,7 +8,7 @@
|
||||
// option. This file may not be copied, modified, or distributed
|
||||
// except according to those terms.
|
||||
|
||||
#[crate_id="trait_default_method_xc_aux"];
|
||||
#![crate_id="trait_default_method_xc_aux"]
|
||||
|
||||
pub struct Something { pub x: int }
|
||||
|
||||
|
@ -11,7 +11,7 @@
|
||||
// Test library crate for cross-crate usages of traits inheriting
|
||||
// from the builtin kinds. Mostly tests metadata correctness.
|
||||
|
||||
#[crate_type="lib"];
|
||||
#![crate_type="lib"]
|
||||
|
||||
pub trait RequiresShare : Share { }
|
||||
pub trait RequiresRequiresShareAndSend : RequiresShare + Send { }
|
||||
|
@ -8,7 +8,7 @@
|
||||
// option. This file may not be copied, modified, or distributed
|
||||
// except according to those terms.
|
||||
|
||||
#[crate_type="lib"];
|
||||
#![crate_type="lib"]
|
||||
|
||||
pub struct Struct {
|
||||
pub x: int
|
||||
|
@ -8,7 +8,7 @@
|
||||
// option. This file may not be copied, modified, or distributed
|
||||
// except according to those terms.
|
||||
|
||||
#[crate_type = "lib"];
|
||||
#![crate_type = "lib"]
|
||||
|
||||
// used by the rpass test
|
||||
|
||||
|
@ -10,7 +10,7 @@
|
||||
|
||||
// Microbenchmarks for various functions in std and extra
|
||||
|
||||
#[feature(macro_rules)];
|
||||
#![feature(macro_rules)]
|
||||
|
||||
extern crate rand;
|
||||
extern crate time;
|
||||
|
@ -10,7 +10,7 @@
|
||||
// option. This file may not be copied, modified, or distributed
|
||||
// except according to those terms.
|
||||
|
||||
#[feature(managed_boxes)];
|
||||
#![feature(managed_boxes)]
|
||||
|
||||
use std::io;
|
||||
use std::io::stdio::StdReader;
|
||||
|
@ -8,7 +8,7 @@
|
||||
// option. This file may not be copied, modified, or distributed
|
||||
// except according to those terms.
|
||||
|
||||
#[feature(managed_boxes)];
|
||||
#![feature(managed_boxes)]
|
||||
|
||||
extern crate collections;
|
||||
extern crate time;
|
||||
|
@ -10,7 +10,7 @@
|
||||
|
||||
// error-pattern: unreachable statement
|
||||
|
||||
#[deny(unreachable_code)];
|
||||
#![deny(unreachable_code)]
|
||||
|
||||
fn main() {
|
||||
return;
|
||||
|
@ -10,5 +10,5 @@
|
||||
|
||||
// error-pattern: missing documentation for crate
|
||||
|
||||
#[deny(missing_doc)];
|
||||
#[crate_type="lib"];
|
||||
#![deny(missing_doc)]
|
||||
#![crate_type="lib"]
|
||||
|
@ -14,7 +14,7 @@
|
||||
|
||||
// error-pattern: dylib output requested, but some depenencies could not
|
||||
|
||||
#[crate_type = "dylib"];
|
||||
#![crate_type = "dylib"]
|
||||
|
||||
extern crate a = "issue-12133-rlib";
|
||||
extern crate b = "issue-12133-dylib";
|
||||
|
@ -8,7 +8,7 @@
|
||||
// option. This file may not be copied, modified, or distributed
|
||||
// except according to those terms.
|
||||
|
||||
#[feature(macro_rules)];
|
||||
#![feature(macro_rules)]
|
||||
|
||||
// error-pattern: unknown macro variable `nonexistent`
|
||||
|
||||
|
@ -10,7 +10,7 @@
|
||||
|
||||
// error-pattern: unreachable statement
|
||||
|
||||
#[deny(unreachable_code)];
|
||||
#![deny(unreachable_code)]
|
||||
|
||||
fn f() -> ! {
|
||||
return fail!();
|
||||
|
@ -10,7 +10,7 @@
|
||||
|
||||
// error-pattern: multiple macro registration functions found
|
||||
|
||||
#[feature(macro_registrar)];
|
||||
#![feature(macro_registrar)]
|
||||
|
||||
// the registration function isn't typechecked yet
|
||||
#[macro_registrar]
|
||||
|
@ -14,7 +14,7 @@
|
||||
So we try to compile with junk link_args and make sure they are visible in
|
||||
the compiler output. */
|
||||
|
||||
#[feature(link_args)];
|
||||
#![feature(link_args)]
|
||||
|
||||
#[link_args = "aFdEfSeVEEE"]
|
||||
extern {}
|
||||
|
@ -8,7 +8,7 @@
|
||||
// option. This file may not be copied, modified, or distributed
|
||||
// except according to those terms.
|
||||
|
||||
#[no_std];
|
||||
#![no_std]
|
||||
|
||||
// error-pattern:requires `start` lang_item
|
||||
|
||||
|
@ -11,7 +11,7 @@
|
||||
// error-pattern:mismatched types: expected `char` but found
|
||||
// Issue #876
|
||||
|
||||
#[no_implicit_prelude];
|
||||
#![no_implicit_prelude]
|
||||
use std::vec::Vec;
|
||||
|
||||
fn last<T>(v: Vec<&T> ) -> std::option::Option<T> {
|
||||
|
Some files were not shown because too many files have changed in this diff Show More
Loading…
Reference in New Issue
Block a user