3737//! also be emitted during HIR ty lowering.
3838
3939use std:: iter;
40- use std:: marker:: PhantomData ;
4140
4241use ast:: visit:: Visitor ;
4342use hir:: def:: { DefKind , PartialRes , Res } ;
@@ -420,7 +419,6 @@ impl<'hir, R: ResolverAstLoweringExt<'hir>> LoweringContext<'_, 'hir, R> {
420419 resolver : this. resolver ,
421420 path_id : delegation. id ,
422421 self_param_id : pat_node_id,
423- phantom : PhantomData ,
424422 } ;
425423 self_resolver. visit_block ( block) ;
426424 // Target expr needs to lower `self` path.
@@ -673,14 +671,13 @@ impl<'hir, R: ResolverAstLoweringExt<'hir>> LoweringContext<'_, 'hir, R> {
673671 }
674672}
675673
676- struct SelfResolver < ' a , ' tcx , R > {
674+ struct SelfResolver < ' a , R > {
677675 resolver : & ' a mut R ,
678676 path_id : NodeId ,
679677 self_param_id : NodeId ,
680- phantom : PhantomData < & ' tcx ( ) > ,
681678}
682679
683- impl < ' tcx , R : ResolverAstLoweringExt < ' tcx > > SelfResolver < ' _ , ' tcx , R > {
680+ impl < ' tcx , R : ResolverAstLoweringExt < ' tcx > > SelfResolver < ' _ , R > {
684681 fn try_replace_id ( & mut self , id : NodeId ) {
685682 if let Some ( res) = self . resolver . get_partial_res ( id)
686683 && let Some ( Res :: Local ( sig_id) ) = res. full_res ( )
@@ -692,7 +689,7 @@ impl<'tcx, R: ResolverAstLoweringExt<'tcx>> SelfResolver<'_, 'tcx, R> {
692689 }
693690}
694691
695- impl < ' ast , ' a , ' tcx , R : ResolverAstLoweringExt < ' tcx > > Visitor < ' ast > for SelfResolver < ' a , ' tcx , R > {
692+ impl < ' ast , ' tcx , R : ResolverAstLoweringExt < ' tcx > > Visitor < ' ast > for SelfResolver < ' _ , R > {
696693 fn visit_id ( & mut self , id : NodeId ) {
697694 self . try_replace_id ( id) ;
698695 }
0 commit comments