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