@@ -110,14 +110,14 @@ fn push_debuginfo_type_name<'tcx>(
110
110
ty_and_layout,
111
111
& |output, visited| {
112
112
push_item_name ( tcx, def. did ( ) , true , output) ;
113
- push_generic_params_internal ( tcx, args, def . did ( ) , output, visited) ;
113
+ push_generic_params_internal ( tcx, args, output, visited) ;
114
114
} ,
115
115
output,
116
116
visited,
117
117
) ;
118
118
} else {
119
119
push_item_name ( tcx, def. did ( ) , qualified, output) ;
120
- push_generic_params_internal ( tcx, args, def . did ( ) , output, visited) ;
120
+ push_generic_params_internal ( tcx, args, output, visited) ;
121
121
}
122
122
}
123
123
ty:: Tuple ( component_types) => {
@@ -251,13 +251,8 @@ fn push_debuginfo_type_name<'tcx>(
251
251
let principal =
252
252
tcx. normalize_erasing_late_bound_regions ( ty:: ParamEnv :: reveal_all ( ) , principal) ;
253
253
push_item_name ( tcx, principal. def_id , qualified, output) ;
254
- let principal_has_generic_params = push_generic_params_internal (
255
- tcx,
256
- principal. args ,
257
- principal. def_id ,
258
- output,
259
- visited,
260
- ) ;
254
+ let principal_has_generic_params =
255
+ push_generic_params_internal ( tcx, principal. args , output, visited) ;
261
256
262
257
let projection_bounds: SmallVec < [ _ ; 4 ] > = trait_data
263
258
. projection_bounds ( )
@@ -538,13 +533,7 @@ pub fn compute_debuginfo_vtable_name<'tcx>(
538
533
tcx. normalize_erasing_late_bound_regions ( ty:: ParamEnv :: reveal_all ( ) , trait_ref) ;
539
534
push_item_name ( tcx, trait_ref. def_id , true , & mut vtable_name) ;
540
535
visited. clear ( ) ;
541
- push_generic_params_internal (
542
- tcx,
543
- trait_ref. args ,
544
- trait_ref. def_id ,
545
- & mut vtable_name,
546
- & mut visited,
547
- ) ;
536
+ push_generic_params_internal ( tcx, trait_ref. args , & mut vtable_name, & mut visited) ;
548
537
} else {
549
538
vtable_name. push ( '_' ) ;
550
539
}
@@ -647,12 +636,11 @@ fn push_unqualified_item_name(
647
636
fn push_generic_params_internal < ' tcx > (
648
637
tcx : TyCtxt < ' tcx > ,
649
638
args : GenericArgsRef < ' tcx > ,
650
- def_id : DefId ,
651
639
output : & mut String ,
652
640
visited : & mut FxHashSet < Ty < ' tcx > > ,
653
641
) -> bool {
654
642
assert_eq ! ( args, tcx. normalize_erasing_regions( ty:: ParamEnv :: reveal_all( ) , args) ) ;
655
- let mut args = args. non_erasable_generics ( tcx , def_id ) . peekable ( ) ;
643
+ let mut args = args. non_erasable_generics ( ) . peekable ( ) ;
656
644
if args. peek ( ) . is_none ( ) {
657
645
return false ;
658
646
}
@@ -736,12 +724,11 @@ fn push_const_param<'tcx>(tcx: TyCtxt<'tcx>, ct: ty::Const<'tcx>, output: &mut S
736
724
pub fn push_generic_params < ' tcx > (
737
725
tcx : TyCtxt < ' tcx > ,
738
726
args : GenericArgsRef < ' tcx > ,
739
- def_id : DefId ,
740
727
output : & mut String ,
741
728
) {
742
729
let _prof = tcx. prof . generic_activity ( "compute_debuginfo_type_name" ) ;
743
730
let mut visited = FxHashSet :: default ( ) ;
744
- push_generic_params_internal ( tcx, args, def_id , output, & mut visited) ;
731
+ push_generic_params_internal ( tcx, args, output, & mut visited) ;
745
732
}
746
733
747
734
fn push_closure_or_coroutine_name < ' tcx > (
@@ -786,7 +773,7 @@ fn push_closure_or_coroutine_name<'tcx>(
786
773
// FIXME(async_closures): This is probably not going to be correct w.r.t.
787
774
// multiple coroutine flavors. Maybe truncate to (parent + 1)?
788
775
let args = args. truncate_to ( tcx, generics) ;
789
- push_generic_params_internal ( tcx, args, enclosing_fn_def_id , output, visited) ;
776
+ push_generic_params_internal ( tcx, args, output, visited) ;
790
777
}
791
778
792
779
fn push_close_angle_bracket ( cpp_like_debuginfo : bool , output : & mut String ) {
0 commit comments