From 3b158b3e425b8adb42eab076acc9962bb22783ca Mon Sep 17 00:00:00 2001 From: "Felix S. Klock II" Date: Thu, 18 Jul 2013 09:35:12 +0200 Subject: [PATCH] Silence various warnings in bootstrap build. --- src/librustc/rustc.rs | 1 - src/librustdoc/path_pass.rs | 2 -- src/librustdoc/rustdoc.rs | 2 -- src/librustdoc/sort_pass.rs | 2 -- src/librustdoc/text_pass.rs | 1 - src/libsyntax/ast_map.rs | 1 - src/libsyntax/ast_util.rs | 2 -- src/libsyntax/parse/parser.rs | 6 +----- 8 files changed, 1 insertion(+), 16 deletions(-) diff --git a/src/librustc/rustc.rs b/src/librustc/rustc.rs index a2e6527489c..6a6f6ed6247 100644 --- a/src/librustc/rustc.rs +++ b/src/librustc/rustc.rs @@ -17,7 +17,6 @@ #[license = "MIT/ASL2"]; #[crate_type = "lib"]; -#[allow(non_implicitly_copyable_typarams)]; #[deny(deprecated_pattern)]; extern mod extra; diff --git a/src/librustdoc/path_pass.rs b/src/librustdoc/path_pass.rs index b333417f2f8..413df2f3358 100644 --- a/src/librustdoc/path_pass.rs +++ b/src/librustdoc/path_pass.rs @@ -43,7 +43,6 @@ fn clone(&self) -> Ctxt { } } -#[allow(non_implicitly_copyable_typarams)] fn run(srv: astsrv::Srv, doc: doc::Doc) -> doc::Doc { let ctxt = Ctxt { srv: srv, @@ -66,7 +65,6 @@ fn fold_item(fold: &fold::Fold, doc: doc::ItemDoc) -> doc::ItemDoc { } } -#[allow(non_implicitly_copyable_typarams)] fn fold_mod(fold: &fold::Fold, doc: doc::ModDoc) -> doc::ModDoc { let is_topmod = doc.id() == ast::crate_node_id; diff --git a/src/librustdoc/rustdoc.rs b/src/librustdoc/rustdoc.rs index 644f3d78cf4..cd2ffd7d602 100644 --- a/src/librustdoc/rustdoc.rs +++ b/src/librustdoc/rustdoc.rs @@ -19,8 +19,6 @@ #[license = "MIT/ASL2"]; #[crate_type = "lib"]; -#[allow(non_implicitly_copyable_typarams)]; - extern mod extra; extern mod rustc; extern mod syntax; diff --git a/src/librustdoc/sort_pass.rs b/src/librustdoc/sort_pass.rs index 8b973c78d73..5119f1e3bfc 100644 --- a/src/librustdoc/sort_pass.rs +++ b/src/librustdoc/sort_pass.rs @@ -42,7 +42,6 @@ pub fn mk_pass(name: ~str, lteq: ItemLtEqOp) -> Pass { } } -#[allow(non_implicitly_copyable_typarams)] fn run( _srv: astsrv::Srv, doc: doc::Doc, @@ -55,7 +54,6 @@ fn run( (fold.fold_doc)(&fold, doc) } -#[allow(non_implicitly_copyable_typarams)] fn fold_mod( fold: &fold::Fold, doc: doc::ModDoc diff --git a/src/librustdoc/text_pass.rs b/src/librustdoc/text_pass.rs index 5121a312d93..41c0dcfb6d2 100644 --- a/src/librustdoc/text_pass.rs +++ b/src/librustdoc/text_pass.rs @@ -44,7 +44,6 @@ fn clone(&self) -> WrappedOp { } } -#[allow(non_implicitly_copyable_typarams)] fn run( _srv: astsrv::Srv, doc: doc::Doc, diff --git a/src/libsyntax/ast_map.rs b/src/libsyntax/ast_map.rs index 721f5108cc0..aef201a0232 100644 --- a/src/libsyntax/ast_map.rs +++ b/src/libsyntax/ast_map.rs @@ -20,7 +20,6 @@ use visit; use syntax::parse::token::special_idents; -use std::cmp; use std::hashmap::HashMap; use std::vec; diff --git a/src/libsyntax/ast_util.rs b/src/libsyntax/ast_util.rs index 09fea560f37..97e940805bb 100644 --- a/src/libsyntax/ast_util.rs +++ b/src/libsyntax/ast_util.rs @@ -16,8 +16,6 @@ use parse::token; use visit; -use std::cast::unsafe_copy; -use std::cast; use std::hashmap::HashMap; use std::int; use std::local_data; diff --git a/src/libsyntax/parse/parser.rs b/src/libsyntax/parse/parser.rs index 42951543cd2..fb5d3b5262c 100644 --- a/src/libsyntax/parse/parser.rs +++ b/src/libsyntax/parse/parser.rs @@ -2713,7 +2713,6 @@ pub fn parse_pat(&self) -> @pat { token::LBRACE => { self.bump(); let (_, _) = self.parse_pat_fields(); - hi = self.span.hi; self.bump(); self.obsolete(*self.span, ObsoleteRecordPattern); pat = pat_wild; @@ -2744,7 +2743,6 @@ pub fn parse_pat(&self) -> @pat { } } if fields.len() == 1 { self.expect(&token::COMMA); } - hi = self.span.hi; self.expect(&token::RPAREN); pat = pat_tup(fields); } @@ -2760,7 +2758,6 @@ pub fn parse_pat(&self) -> @pat { self.bump(); let (before, slice, after) = self.parse_pat_vec_elements(); - hi = self.span.hi; self.expect(&token::RBRACKET); pat = ast::pat_vec(before, slice, after); hi = self.last_span.hi; @@ -4654,7 +4651,7 @@ fn parse_macro_use_or_failure( pub fn parse_item(&self, attrs: ~[attribute]) -> Option<@ast::item> { match self.parse_item_or_view_item(attrs, true) { - iovi_none(attrs) => + iovi_none(_) => None, iovi_view_item(_) => self.fatal("view items are not allowed here"), @@ -4824,7 +4821,6 @@ fn parse_items_and_view_items(&self, // First, parse view items. let mut view_items : ~[ast::view_item] = ~[]; let mut items = ~[]; - let mut done = false; // I think this code would probably read better as a single // loop with a mutable three-state-variable (for extern mods, // view items, and regular items) ... except that because -- GitLab