Clean up warnings
This commit is contained in:
parent
47eca2113c
commit
7ce68dc9e1
@ -34,9 +34,6 @@ use std::cast::transmute;
|
||||
use std::cast;
|
||||
use std::hashmap::{HashMap};
|
||||
use std::libc::{c_uint, c_longlong, c_ulonglong};
|
||||
use std::to_bytes;
|
||||
use std::str;
|
||||
use std::vec::raw::to_ptr;
|
||||
use std::vec;
|
||||
use syntax::ast::ident;
|
||||
use syntax::ast_map::{path, path_elt};
|
||||
|
@ -548,7 +548,6 @@ pub fn trans_trait_callee_from_llval(bcx: block,
|
||||
|
||||
let _icx = push_ctxt("impl::trans_trait_callee");
|
||||
let ccx = bcx.ccx();
|
||||
let mut bcx = bcx;
|
||||
|
||||
// Load the vtable from the @Trait pair
|
||||
debug!("(translating trait callee) loading vtable from pair %s",
|
||||
|
@ -9,7 +9,6 @@
|
||||
// except according to those terms.
|
||||
|
||||
|
||||
use back;
|
||||
use lib::llvm::ValueRef;
|
||||
use middle::trans::base::*;
|
||||
use middle::trans::build::*;
|
||||
|
@ -463,7 +463,6 @@ pub fn check_fn(ccx: @mut CrateCtxt,
|
||||
}
|
||||
|
||||
// Check the pattern.
|
||||
let region = fcx.block_region();
|
||||
let pcx = pat_ctxt {
|
||||
fcx: fcx,
|
||||
map: pat_id_map(tcx.def_map, input.pat),
|
||||
@ -2892,7 +2891,6 @@ pub fn check_decl_local(fcx: @mut FnCtxt, local: @ast::local) {
|
||||
_ => {}
|
||||
}
|
||||
|
||||
let region = tcx.region_maps.encl_region(local.node.id);
|
||||
let pcx = pat_ctxt {
|
||||
fcx: fcx,
|
||||
map: pat_id_map(tcx.def_map, local.node.pat),
|
||||
|
@ -36,11 +36,9 @@ use middle::typeck::check::regionmanip::relate_nested_regions;
|
||||
use middle::typeck::infer::resolve_and_force_all_but_regions;
|
||||
use middle::typeck::infer::resolve_type;
|
||||
use middle::typeck::infer;
|
||||
use util::ppaux::{note_and_explain_region, ty_to_str,
|
||||
region_to_str};
|
||||
use util::ppaux::{ty_to_str, region_to_str};
|
||||
use middle::pat_util;
|
||||
|
||||
use std::result;
|
||||
use std::uint;
|
||||
use syntax::ast::{ManagedSigil, OwnedSigil, BorrowedSigil};
|
||||
use syntax::ast::{def_arg, def_binding, def_local, def_self, def_upvar};
|
||||
@ -419,8 +417,6 @@ fn constrain_callee(rcx: @mut Rcx,
|
||||
call_expr: @ast::expr,
|
||||
callee_expr: @ast::expr)
|
||||
{
|
||||
let tcx = rcx.fcx.tcx();
|
||||
|
||||
let call_region = ty::re_scope(call_expr.id);
|
||||
|
||||
let callee_ty = rcx.resolve_node_type(callee_id);
|
||||
@ -559,8 +555,6 @@ fn constrain_index(rcx: @mut Rcx,
|
||||
* includes the deref expr.
|
||||
*/
|
||||
|
||||
let tcx = rcx.fcx.tcx();
|
||||
|
||||
debug!("constrain_index(index_expr=?, indexed_ty=%s",
|
||||
rcx.fcx.infcx().ty_to_str(indexed_ty));
|
||||
|
||||
|
@ -65,7 +65,7 @@ use middle::typeck::infer::sub::Sub;
|
||||
use middle::typeck::infer::to_str::InferStr;
|
||||
use middle::typeck::infer::unify::{InferCtxtMethods};
|
||||
use middle::typeck::infer::{InferCtxt, cres, ures};
|
||||
use middle::typeck::infer::{TypeOrigin, TypeTrace};
|
||||
use middle::typeck::infer::{TypeTrace};
|
||||
use util::common::indent;
|
||||
|
||||
use std::result::{iter_vec2, map_vec2};
|
||||
@ -73,7 +73,6 @@ use std::vec;
|
||||
use syntax::ast::{Onceness, purity};
|
||||
use syntax::ast;
|
||||
use syntax::opt_vec;
|
||||
use syntax::codemap::span;
|
||||
use syntax::abi::AbiSet;
|
||||
|
||||
pub trait Combine {
|
||||
|
@ -59,23 +59,18 @@ time of error detection.
|
||||
|
||||
*/
|
||||
|
||||
use std::prelude::*;
|
||||
use middle::ty;
|
||||
use middle::ty::Region;
|
||||
use middle::typeck::infer;
|
||||
use middle::typeck::infer::InferCtxt;
|
||||
use middle::typeck::infer::TypeTrace;
|
||||
use middle::typeck::infer::TypeOrigin;
|
||||
use middle::typeck::infer::SubregionOrigin;
|
||||
use middle::typeck::infer::RegionVariableOrigin;
|
||||
use middle::typeck::infer::Types;
|
||||
use middle::typeck::infer::TraitRefs;
|
||||
use middle::typeck::infer::ValuePairs;
|
||||
use middle::typeck::infer::region_inference::RegionResolutionError;
|
||||
use middle::typeck::infer::region_inference::ConcreteFailure;
|
||||
use middle::typeck::infer::region_inference::SubSupConflict;
|
||||
use middle::typeck::infer::region_inference::SupSupConflict;
|
||||
use syntax::opt_vec;
|
||||
use syntax::opt_vec::OptVec;
|
||||
use util::ppaux::UserString;
|
||||
use util::ppaux::note_and_explain_region;
|
||||
@ -362,7 +357,7 @@ impl ErrorReporting for InferCtxt {
|
||||
sup,
|
||||
"");
|
||||
}
|
||||
infer::ReferenceOutlivesReferent(ty, span) => {
|
||||
infer::ReferenceOutlivesReferent(ty, _) => {
|
||||
self.tcx.sess.span_err(
|
||||
origin.span(),
|
||||
fmt!("in type `%s`, pointer has a longer lifetime than \
|
||||
|
@ -26,8 +26,7 @@ use syntax::ast::{Many, Once, extern_fn, impure_fn, m_const, m_imm, m_mutbl};
|
||||
use syntax::ast::{unsafe_fn};
|
||||
use syntax::ast::{Onceness, purity};
|
||||
use syntax::abi::AbiSet;
|
||||
use syntax::codemap::span;
|
||||
use util::common::{indent, indenter};
|
||||
use util::common::{indenter};
|
||||
use util::ppaux::mt_to_str;
|
||||
|
||||
use extra::list;
|
||||
|
@ -21,7 +21,6 @@ use middle::typeck::infer::{cres, InferCtxt};
|
||||
use middle::typeck::infer::fold_regions_in_sig;
|
||||
use middle::typeck::infer::{TypeTrace, Subtype};
|
||||
use middle::typeck::isr_alist;
|
||||
use util::common::indent;
|
||||
use util::ppaux::mt_to_str;
|
||||
|
||||
use extra::list;
|
||||
@ -30,7 +29,6 @@ use syntax::ast;
|
||||
use syntax::ast::{Many, Once, extern_fn, m_const, impure_fn};
|
||||
use syntax::ast::{unsafe_fn};
|
||||
use syntax::ast::{Onceness, purity};
|
||||
use syntax::codemap::span;
|
||||
|
||||
pub struct Lub(CombineFields); // least-upper-bound: common supertype
|
||||
|
||||
|
@ -328,7 +328,7 @@ pub fn can_mk_subty(cx: @mut InferCtxt, a: ty::t, b: ty::t) -> ures {
|
||||
}
|
||||
|
||||
pub fn mk_subr(cx: @mut InferCtxt,
|
||||
a_is_expected: bool,
|
||||
_a_is_expected: bool,
|
||||
origin: SubregionOrigin,
|
||||
a: ty::Region,
|
||||
b: ty::Region) {
|
||||
|
@ -19,13 +19,12 @@ use middle::typeck::infer::cres;
|
||||
use middle::typeck::infer::{RegionVariableOrigin, SubregionOrigin};
|
||||
use middle::typeck::infer;
|
||||
use util::common::indenter;
|
||||
use util::ppaux::{note_and_explain_region, Repr, UserString};
|
||||
use util::ppaux::{Repr};
|
||||
|
||||
use std::cell::Cell;
|
||||
use std::hashmap::{HashMap, HashSet};
|
||||
use std::uint;
|
||||
use std::vec;
|
||||
use syntax::codemap::span;
|
||||
use syntax::ast;
|
||||
use syntax::opt_vec;
|
||||
use syntax::opt_vec::OptVec;
|
||||
|
@ -21,7 +21,7 @@ use middle::typeck::infer::lattice::CombineFieldsLatticeMethods;
|
||||
use middle::typeck::infer::lub::Lub;
|
||||
use middle::typeck::infer::to_str::InferStr;
|
||||
use middle::typeck::infer::{TypeTrace, Subtype};
|
||||
use util::common::{indent, indenter};
|
||||
use util::common::{indenter};
|
||||
use util::ppaux::bound_region_to_str;
|
||||
|
||||
use extra::list::Nil;
|
||||
@ -29,7 +29,6 @@ use extra::list;
|
||||
use syntax::abi::AbiSet;
|
||||
use syntax::ast;
|
||||
use syntax::ast::{Onceness, m_const, purity};
|
||||
use syntax::codemap::span;
|
||||
|
||||
pub struct Sub(CombineFields); // "subtype", "subregion" etc
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user