@@ -185,20 +185,20 @@ impl<'a, 'tcx> FnCtxt<'a, 'tcx> {
185185 if !method. substs . is_empty ( ) {
186186 let method_generics = self . tcx . generics_of ( method. def_id ) ;
187187 if !method_generics. params . is_empty ( ) {
188- let user_type_annotation = self . infcx . probe ( |_| {
188+ let user_type_annotation = self . probe ( |_| {
189189 let user_substs = UserSubsts {
190190 substs : InternalSubsts :: for_item ( self . tcx , method. def_id , |param, _| {
191191 let i = param. index as usize ;
192192 if i < method_generics. parent_count {
193- self . infcx . var_for_def ( DUMMY_SP , param)
193+ self . var_for_def ( DUMMY_SP , param)
194194 } else {
195195 method. substs [ i]
196196 }
197197 } ) ,
198198 user_self_ty : None , // not relevant here
199199 } ;
200200
201- self . infcx . canonicalize_user_type_annotation ( UserType :: TypeOf (
201+ self . canonicalize_user_type_annotation ( UserType :: TypeOf (
202202 method. def_id ,
203203 user_substs,
204204 ) )
@@ -236,7 +236,7 @@ impl<'a, 'tcx> FnCtxt<'a, 'tcx> {
236236 debug ! ( "fcx {}" , self . tag( ) ) ;
237237
238238 if Self :: can_contain_user_lifetime_bounds ( ( substs, user_self_ty) ) {
239- let canonicalized = self . infcx . canonicalize_user_type_annotation ( UserType :: TypeOf (
239+ let canonicalized = self . canonicalize_user_type_annotation ( UserType :: TypeOf (
240240 def_id,
241241 UserSubsts { substs, user_self_ty } ,
242242 ) ) ;
@@ -480,7 +480,7 @@ impl<'a, 'tcx> FnCtxt<'a, 'tcx> {
480480 debug ! ( "to_ty_saving_user_provided_ty: ty={:?}" , ty) ;
481481
482482 if Self :: can_contain_user_lifetime_bounds ( ty) {
483- let c_ty = self . infcx . canonicalize_response ( UserType :: Ty ( ty) ) ;
483+ let c_ty = self . canonicalize_response ( UserType :: Ty ( ty) ) ;
484484 debug ! ( "to_ty_saving_user_provided_ty: c_ty={:?}" , c_ty) ;
485485 self . typeck_results . borrow_mut ( ) . user_provided_types_mut ( ) . insert ( ast_ty. hir_id , c_ty) ;
486486 }
@@ -764,7 +764,7 @@ impl<'a, 'tcx> FnCtxt<'a, 'tcx> {
764764 if let ty:: subst:: GenericArgKind :: Type ( ty) = ty. unpack ( )
765765 && let ty:: Opaque ( def_id, _) = * ty. kind ( )
766766 && let Some ( def_id) = def_id. as_local ( )
767- && self . infcx . opaque_type_origin ( def_id, DUMMY_SP ) . is_some ( ) {
767+ && self . opaque_type_origin ( def_id, DUMMY_SP ) . is_some ( ) {
768768 return None ;
769769 }
770770 }
@@ -826,7 +826,7 @@ impl<'a, 'tcx> FnCtxt<'a, 'tcx> {
826826 } else {
827827 self . tcx . bound_type_of ( def_id)
828828 } ;
829- let substs = self . infcx . fresh_substs_for_item ( span, def_id) ;
829+ let substs = self . fresh_substs_for_item ( span, def_id) ;
830830 let ty = item_ty. subst ( self . tcx , substs) ;
831831
832832 self . write_resolution ( hir_id, Ok ( ( def_kind, def_id) ) ) ;
0 commit comments