@@ -4161,7 +4161,7 @@ impl<'hir> Item<'hir> {
41614161 Ident ,
41624162 & ' hir Generics <' hir>,
41634163 GenericBounds <' hir>,
4164- & ' hir [ TraitItemRef ]
4164+ & ' hir [ TraitItemId ]
41654165 ) ,
41664166 ItemKind :: Trait ( is_auto, safety, ident, generics, bounds, items) ,
41674167 ( * is_auto, * safety, * ident, generics, bounds, items) ;
@@ -4334,7 +4334,7 @@ pub enum ItemKind<'hir> {
43344334 /// A union definition, e.g., `union Foo<A, B> {x: A, y: B}`.
43354335 Union ( Ident , & ' hir Generics < ' hir > , VariantData < ' hir > ) ,
43364336 /// A trait definition.
4337- Trait ( IsAuto , Safety , Ident , & ' hir Generics < ' hir > , GenericBounds < ' hir > , & ' hir [ TraitItemRef ] ) ,
4337+ Trait ( IsAuto , Safety , Ident , & ' hir Generics < ' hir > , GenericBounds < ' hir > , & ' hir [ TraitItemId ] ) ,
43384338 /// A trait alias.
43394339 TraitAlias ( Ident , & ' hir Generics < ' hir > , GenericBounds < ' hir > ) ,
43404340
@@ -4361,7 +4361,7 @@ pub struct Impl<'hir> {
43614361 pub of_trait : Option < TraitRef < ' hir > > ,
43624362
43634363 pub self_ty : & ' hir Ty < ' hir > ,
4364- pub items : & ' hir [ ImplItemRef ] ,
4364+ pub items : & ' hir [ ImplItemId ] ,
43654365}
43664366
43674367impl ItemKind < ' _ > {
@@ -4404,32 +4404,6 @@ impl ItemKind<'_> {
44044404 }
44054405}
44064406
4407- /// A reference from an trait to one of its associated items. This
4408- /// contains the item's id, naturally, but also the item's name and
4409- /// some other high-level details (like whether it is an associated
4410- /// type or method, and whether it is public). This allows other
4411- /// passes to find the impl they want without loading the ID (which
4412- /// means fewer edges in the incremental compilation graph).
4413- #[ derive( Debug , Clone , Copy , HashStable_Generic ) ]
4414- pub struct TraitItemRef {
4415- pub id : TraitItemId ,
4416- pub ident : Ident ,
4417- pub span : Span ,
4418- }
4419-
4420- /// A reference from an impl to one of its associated items. This
4421- /// contains the item's ID, naturally, but also the item's name and
4422- /// some other high-level details (like whether it is an associated
4423- /// type or method, and whether it is public). This allows other
4424- /// passes to find the impl they want without loading the ID (which
4425- /// means fewer edges in the incremental compilation graph).
4426- #[ derive( Debug , Clone , Copy , HashStable_Generic ) ]
4427- pub struct ImplItemRef {
4428- pub id : ImplItemId ,
4429- pub ident : Ident ,
4430- pub span : Span ,
4431- }
4432-
44334407// The bodies for items are stored "out of line", in a separate
44344408// hashmap in the `Crate`. Here we just record the hir-id of the item
44354409// so it can fetched later.
0 commit comments