diff --git a/src/librustc_typeck/astconv.rs b/src/librustc_typeck/astconv.rs index 5e05f7d8fce..43e7aee1b12 100644 --- a/src/librustc_typeck/astconv.rs +++ b/src/librustc_typeck/astconv.rs @@ -20,7 +20,7 @@ use hir::HirVec; use lint; use middle::resolve_lifetime as rl; use namespace::Namespace; -use rustc::traits::{self, TraitRefExpansionInfoDignosticBuilder}; +use rustc::traits; use rustc::ty::{self, Ty, TyCtxt, ToPredicate, TypeFoldable}; use rustc::ty::{GenericParamDef, GenericParamDefKind}; use rustc::ty::subst::{Kind, Subst, Substs}; @@ -39,7 +39,6 @@ use util::nodemap::FxHashMap; use std::collections::BTreeSet; use std::iter; -use std::ops::Range; use std::slice; pub trait AstConv<'gcx, 'tcx> { diff --git a/src/librustc_typeck/check/method/suggest.rs b/src/librustc_typeck/check/method/suggest.rs index 79414cba69b..b76c9101eae 100644 --- a/src/librustc_typeck/check/method/suggest.rs +++ b/src/librustc_typeck/check/method/suggest.rs @@ -309,10 +309,10 @@ impl<'a, 'gcx, 'tcx> FnCtxt<'a, 'gcx, 'tcx> { "no {} named `{}` found for type `{}` in the current scope", item_kind, item_name, - ty_string + ty_str ); if let Some(suggestion) = suggestion { - err.note(&format!("did you mean `{}::{}`?", ty_string, suggestion)); + err.note(&format!("did you mean `{}::{}`?", ty_str, suggestion)); } err } @@ -651,7 +651,7 @@ impl<'a, 'gcx, 'tcx> FnCtxt<'a, 'gcx, 'tcx> { fn type_derefs_to_local(&self, span: Span, rcvr_ty: Ty<'tcx>, - source: SelfSource) -> bool { + rcvr_expr: Option<&hir::Expr>) -> bool { fn is_local(ty: Ty) -> bool { match ty.sty { ty::Adt(def, _) => def.did.is_local(),