@@ -16,9 +16,10 @@ use rustc_span::hygiene::MacroKind;
1616use rustc_span:: symbol:: { kw, sym, Symbol } ;
1717
1818use crate :: clean:: {
19- self , clean_fn_decl_from_did_and_sig, clean_generics, clean_impl_item, clean_middle_field,
20- clean_middle_ty, clean_trait_ref_with_bindings, clean_ty, clean_ty_generics, clean_variant_def,
21- clean_visibility, utils, Attributes , AttributesExt , Clean , ImplKind , ItemId , Type , Visibility ,
19+ self , clean_fn_decl_from_did_and_sig, clean_generics, clean_impl_item, clean_middle_assoc_item,
20+ clean_middle_field, clean_middle_ty, clean_trait_ref_with_bindings, clean_ty,
21+ clean_ty_generics, clean_variant_def, clean_visibility, utils, Attributes , AttributesExt ,
22+ ImplKind , ItemId , Type , Visibility ,
2223} ;
2324use crate :: core:: DocContext ;
2425use crate :: formats:: item_type:: ItemType ;
@@ -217,7 +218,7 @@ pub(crate) fn build_external_trait(cx: &mut DocContext<'_>, did: DefId) -> clean
217218 // which causes methods to have a `pub` prefix, which is invalid since items in traits
218219 // can not have a visibility prefix. Thus we override the visibility here manually.
219220 // See https://github.com/rust-lang/rust/issues/81274
220- clean:: Item { visibility : Visibility :: Inherited , ..item . clean ( cx) }
221+ clean:: Item { visibility : Visibility :: Inherited , ..clean_middle_assoc_item ( item , cx) }
221222 } )
222223 . collect ( ) ;
223224
@@ -452,7 +453,7 @@ pub(crate) fn build_impl(
452453 item. visibility ( tcx) . is_public ( )
453454 }
454455 } )
455- . map ( |item| item . clean ( cx) )
456+ . map ( |item| clean_middle_assoc_item ( item , cx) )
456457 . collect :: < Vec < _ > > ( ) ,
457458 clean:: enter_impl_trait ( cx, |cx| {
458459 clean_ty_generics ( cx, tcx. generics_of ( did) , predicates)
0 commit comments