Fix warnings
This commit is contained in:
parent
f336afd459
commit
e3327d3833
@ -18,7 +18,6 @@ use metadata::decoder;
|
||||
use metadata::filesearch::FileSearch;
|
||||
use metadata::loader;
|
||||
|
||||
use core::either;
|
||||
use core::hashmap::linear::LinearMap;
|
||||
use core::vec;
|
||||
use syntax::attr;
|
||||
|
@ -18,7 +18,6 @@ use util::ppaux::{ty_to_str};
|
||||
use core::hashmap::linear::LinearMap;
|
||||
use core::char;
|
||||
use core::cmp;
|
||||
use core::either;
|
||||
use core::i8;
|
||||
use core::i16;
|
||||
use core::i32;
|
||||
|
@ -718,8 +718,8 @@ pub impl VisitContext {
|
||||
}
|
||||
|
||||
fn use_receiver(&self,
|
||||
expr_id: node_id,
|
||||
span: span,
|
||||
_expr_id: node_id,
|
||||
_span: span,
|
||||
receiver_expr: @expr,
|
||||
visitor: vt<VisitContext>)
|
||||
{
|
||||
|
@ -1358,7 +1358,7 @@ pub impl Resolver {
|
||||
item_id: def_id,
|
||||
+parent_privacy: Privacy,
|
||||
parent: ReducedGraphParent,
|
||||
&&visitor: vt<ReducedGraphParent>) {
|
||||
&&_visitor: vt<ReducedGraphParent>) {
|
||||
let ident = variant.node.name;
|
||||
let (child, _) = self.add_child(ident, parent, ForbidDuplicateValues,
|
||||
variant.span);
|
||||
|
@ -11,7 +11,7 @@
|
||||
use core::prelude::*;
|
||||
|
||||
use back::abi;
|
||||
use lib::llvm::{llvm, SetLinkage, InternalLinkage, PrivateLinkage,
|
||||
use lib::llvm::{llvm, SetLinkage, PrivateLinkage,
|
||||
ValueRef, TypeRef, Bool, True, False};
|
||||
use metadata::csearch;
|
||||
use middle::const_eval;
|
||||
|
@ -11,7 +11,6 @@
|
||||
use core::prelude::*;
|
||||
|
||||
use back::{link, abi};
|
||||
use driver::session;
|
||||
use lib::llvm::{SequentiallyConsistent, Acquire, Release, Xchg};
|
||||
use lib::llvm::{TypeRef, ValueRef};
|
||||
use lib;
|
||||
|
@ -110,7 +110,6 @@ use util::common::{block_query, indenter, loop_query};
|
||||
use util::ppaux::{bound_region_to_str, expr_repr, pat_repr};
|
||||
use util::ppaux;
|
||||
|
||||
use core::either;
|
||||
use core::hashmap::linear::LinearMap;
|
||||
use core::ptr;
|
||||
use core::result::{Result, Ok, Err};
|
||||
@ -119,7 +118,7 @@ use core::str;
|
||||
use core::vec;
|
||||
use std::list::Nil;
|
||||
use syntax::abi::AbiSet;
|
||||
use syntax::ast::{provided, required, ty_i};
|
||||
use syntax::ast::{provided, required};
|
||||
use syntax::ast;
|
||||
use syntax::ast_map;
|
||||
use syntax::ast_util::local_def;
|
||||
@ -3021,7 +3020,7 @@ pub fn check_enum_variants(ccx: @mut CrateCtxt,
|
||||
vs: &[ast::variant],
|
||||
id: ast::node_id) {
|
||||
fn do_check(ccx: @mut CrateCtxt,
|
||||
sp: span,
|
||||
_sp: span,
|
||||
vs: &[ast::variant],
|
||||
id: ast::node_id,
|
||||
disr_vals: &mut ~[int],
|
||||
@ -3303,7 +3302,7 @@ pub fn type_is_c_like_enum(fcx: @mut FnCtxt, sp: span, typ: ty::t) -> bool {
|
||||
|
||||
pub fn ast_expr_vstore_to_vstore(fcx: @mut FnCtxt,
|
||||
e: @ast::expr,
|
||||
n: uint,
|
||||
_n: uint,
|
||||
v: ast::expr_vstore)
|
||||
-> ty::vstore {
|
||||
match v {
|
||||
|
@ -33,7 +33,7 @@ are represented as `ty_param()` instances.
|
||||
use core::prelude::*;
|
||||
|
||||
use metadata::csearch;
|
||||
use middle::ty::{InstantiatedTraitRef, arg};
|
||||
use middle::ty::InstantiatedTraitRef;
|
||||
use middle::ty::{substs, ty_param_bounds_and_ty, ty_param_substs_and_ty};
|
||||
use middle::ty;
|
||||
use middle::typeck::astconv::{AstConv, ty_of_arg};
|
||||
@ -860,7 +860,7 @@ pub fn ty_of_item(ccx: &CrateCtxt, it: @ast::item)
|
||||
tcx.tcache.insert(local_def(it.id), tpt);
|
||||
return tpt;
|
||||
}
|
||||
ast::item_fn(ref decl, purity, abi, ref generics, _) => {
|
||||
ast::item_fn(ref decl, purity, _, ref generics, _) => {
|
||||
let bounds = ty_param_bounds(ccx, generics);
|
||||
let tofd = astconv::ty_of_bare_fn(ccx,
|
||||
&empty_rscope,
|
||||
|
@ -66,9 +66,9 @@ we may want to adjust precisely when coercions occur.
|
||||
|
||||
use core::prelude::*;
|
||||
|
||||
use middle::ty::{TyVar, AutoPtr, AutoBorrowVec, AutoBorrowFn};
|
||||
use middle::ty::{AutoAdjustment, AutoDerefRef, AutoRef};
|
||||
use middle::ty::{vstore_slice, vstore_box, vstore_uniq, vstore_fixed};
|
||||
use middle::ty::{AutoPtr, AutoBorrowVec, AutoBorrowFn};
|
||||
use middle::ty::{AutoDerefRef, AutoRef};
|
||||
use middle::ty::{vstore_slice, vstore_box, vstore_uniq};
|
||||
use middle::ty::{mt};
|
||||
use middle::ty;
|
||||
use middle::typeck::infer::{CoerceResult, resolve_type};
|
||||
@ -76,10 +76,9 @@ use middle::typeck::infer::combine::CombineFields;
|
||||
use middle::typeck::infer::sub::Sub;
|
||||
use middle::typeck::infer::to_str::InferStr;
|
||||
use middle::typeck::infer::resolve::try_resolve_tvar_shallow;
|
||||
use util::common::{indent, indenter};
|
||||
use util::common::indenter;
|
||||
|
||||
use syntax::abi::AbiSet;
|
||||
use syntax::ast::{m_const, m_imm, m_mutbl};
|
||||
use syntax::ast::m_imm;
|
||||
use syntax::ast;
|
||||
|
||||
// Note: Coerce is not actually a combiner, in that it does not
|
||||
|
@ -21,7 +21,7 @@ use middle::typeck::infer::{cres, InferCtxt};
|
||||
use middle::typeck::isr_alist;
|
||||
use syntax::ast;
|
||||
use syntax::ast::{Many, Once, extern_fn, impure_fn, m_const, m_imm, m_mutbl};
|
||||
use syntax::ast::{noreturn, pure_fn, ret_style, return_val, unsafe_fn};
|
||||
use syntax::ast::{pure_fn, unsafe_fn};
|
||||
use syntax::ast::{Onceness, purity};
|
||||
use syntax::abi::AbiSet;
|
||||
use syntax::codemap::span;
|
||||
|
@ -20,7 +20,6 @@ use uv;
|
||||
use uv::iotask;
|
||||
use uv::iotask::IoTask;
|
||||
|
||||
use core::io::{Reader, ReaderUtil, Writer};
|
||||
use core::io;
|
||||
use core::libc::size_t;
|
||||
use core::libc;
|
||||
@ -1439,7 +1438,7 @@ struct TcpBufferedSocketData {
|
||||
mut buf_off: uint
|
||||
}
|
||||
|
||||
//#[cfg(test)]
|
||||
#[cfg(test)]
|
||||
pub mod test {
|
||||
use net::ip;
|
||||
use net::tcp::{GenericListenErr, TcpConnectErrData, TcpListenErrData};
|
||||
|
@ -10,7 +10,7 @@
|
||||
|
||||
// The Rust abstract syntax tree.
|
||||
|
||||
use codemap::{span, FileName, spanned};
|
||||
use codemap::{span, spanned};
|
||||
use abi::AbiSet;
|
||||
use opt_vec::OptVec;
|
||||
|
||||
|
@ -15,7 +15,6 @@ use ast::*;
|
||||
use ast;
|
||||
use ast_util::{inlined_item_utils, stmt_id};
|
||||
use ast_util;
|
||||
use attr;
|
||||
use codemap;
|
||||
use codemap::spanned;
|
||||
use diagnostic::span_handler;
|
||||
|
@ -19,7 +19,6 @@ use codemap::BytePos;
|
||||
use diagnostic::span_handler;
|
||||
use parse::comments::{doc_comment_style, strip_doc_comment_decoration};
|
||||
|
||||
use core::either::Either;
|
||||
use core::vec;
|
||||
use core::hashmap::linear::LinearSet;
|
||||
use std;
|
||||
|
@ -286,7 +286,7 @@ pub fn create_enum_variant_pattern(cx: @ext_ctxt,
|
||||
}
|
||||
}
|
||||
|
||||
pub fn variant_arg_count(cx: @ext_ctxt, span: span, variant: &variant) -> uint {
|
||||
pub fn variant_arg_count(_cx: @ext_ctxt, _span: span, variant: &variant) -> uint {
|
||||
match variant.node.kind {
|
||||
tuple_variant_kind(ref args) => args.len(),
|
||||
struct_variant_kind(ref struct_def) => struct_def.fields.len(),
|
||||
|
@ -16,7 +16,7 @@
|
||||
use core::prelude::*;
|
||||
|
||||
use abi::AbiSet;
|
||||
use ast::{ident, node_id};
|
||||
use ast::ident;
|
||||
use ast;
|
||||
use ast_util;
|
||||
use codemap::{span, respan, dummy_sp, spanned};
|
||||
|
@ -3777,7 +3777,7 @@ pub impl Parser {
|
||||
};
|
||||
}
|
||||
|
||||
fn parse_enum_def(&self, generics: &ast::Generics) -> enum_def {
|
||||
fn parse_enum_def(&self, _generics: &ast::Generics) -> enum_def {
|
||||
let mut variants = ~[];
|
||||
let mut all_nullary = true, have_disr = false;
|
||||
while *self.token != token::RBRACE {
|
||||
|
@ -11,7 +11,6 @@
|
||||
use core::prelude::*;
|
||||
|
||||
use abi::AbiSet;
|
||||
use abi;
|
||||
use ast::{RegionTyParamBound, TraitTyParamBound, required, provided};
|
||||
use ast;
|
||||
use ast_util;
|
||||
@ -2180,7 +2179,7 @@ pub fn print_opt_sigil(s: @ps, opt_sigil: Option<ast::Sigil>) {
|
||||
}
|
||||
|
||||
pub fn print_fn_header_info(s: @ps,
|
||||
opt_sty: Option<ast::self_ty_>,
|
||||
_opt_sty: Option<ast::self_ty_>,
|
||||
opt_purity: Option<ast::purity>,
|
||||
abis: AbiSet,
|
||||
onceness: ast::Onceness,
|
||||
|
Loading…
Reference in New Issue
Block a user