@@ -1112,15 +1112,15 @@ impl<'a> AsMut<Resolver<'a>> for Resolver<'a> {
1112
1112
/// A minimal subset of resolver that can implemenent `DefIdTree`, sometimes
1113
1113
/// required to satisfy borrow checker by avoiding borrowing the whole resolver.
1114
1114
#[ derive( Clone , Copy ) ]
1115
- struct ResolverTree < ' a , ' b > ( & ' a Definitions , & ' a CrateLoader < ' b > ) ;
1115
+ struct ResolverTree < ' a > ( & ' a Definitions , & ' a CStore ) ;
1116
1116
1117
- impl DefIdTree for ResolverTree < ' _ , ' _ > {
1117
+ impl DefIdTree for ResolverTree < ' _ > {
1118
1118
#[ inline]
1119
1119
fn opt_parent ( self , id : DefId ) -> Option < DefId > {
1120
- let ResolverTree ( definitions, crate_loader ) = self ;
1120
+ let ResolverTree ( definitions, cstore ) = self ;
1121
1121
match id. as_local ( ) {
1122
1122
Some ( id) => definitions. def_key ( id) . parent ,
1123
- None => crate_loader . cstore ( ) . def_key ( id) . parent ,
1123
+ None => cstore. def_key ( id) . parent ,
1124
1124
}
1125
1125
. map ( |index| DefId { index, ..id } )
1126
1126
}
@@ -1129,7 +1129,7 @@ impl DefIdTree for ResolverTree<'_, '_> {
1129
1129
impl < ' a , ' b > DefIdTree for & ' a Resolver < ' b > {
1130
1130
#[ inline]
1131
1131
fn opt_parent ( self , id : DefId ) -> Option < DefId > {
1132
- ResolverTree ( & self . definitions , & self . crate_loader ) . opt_parent ( id)
1132
+ ResolverTree ( & self . definitions , self . cstore ( ) ) . opt_parent ( id)
1133
1133
}
1134
1134
}
1135
1135
0 commit comments