@@ -52,7 +52,7 @@ use rustc_middle::metadata::ModChild;
5252use rustc_middle:: middle:: privacy:: EffectiveVisibilities ;
5353use rustc_middle:: query:: Providers ;
5454use rustc_middle:: span_bug;
55- use rustc_middle:: ty:: { self , MainDefinition , RegisteredTools , TyCtxt } ;
55+ use rustc_middle:: ty:: { self , MainDefinition , RegisteredTools , TyCtxt , TyCtxtFeed } ;
5656use rustc_middle:: ty:: { ResolverGlobalCtxt , ResolverOutputs } ;
5757use rustc_query_system:: ich:: StableHashingContext ;
5858use rustc_session:: lint:: builtin:: PRIVATE_MACRO_USE ;
@@ -1234,7 +1234,7 @@ impl<'tcx> Resolver<'_, 'tcx> {
12341234 def_kind : DefKind ,
12351235 expn_id : ExpnId ,
12361236 span : Span ,
1237- ) -> LocalDefId {
1237+ ) -> TyCtxtFeed < ' tcx , LocalDefId > {
12381238 let data = def_kind. def_path_data ( name) ;
12391239 assert ! (
12401240 !self . node_id_to_def_id. contains_key( & node_id) ,
@@ -1245,7 +1245,8 @@ impl<'tcx> Resolver<'_, 'tcx> {
12451245 ) ;
12461246
12471247 // FIXME: remove `def_span` body, pass in the right spans here and call `tcx.at().create_def()`
1248- let def_id = self . tcx . create_def ( parent, name, def_kind) . def_id ( ) ;
1248+ let feed = self . tcx . create_def ( parent, name, def_kind) ;
1249+ let def_id = feed. def_id ( ) ;
12491250
12501251 // Create the definition.
12511252 if expn_id != ExpnId :: root ( ) {
@@ -1266,7 +1267,7 @@ impl<'tcx> Resolver<'_, 'tcx> {
12661267 }
12671268 assert_eq ! ( self . def_id_to_node_id. push( node_id) , def_id) ;
12681269
1269- def_id
1270+ feed
12701271 }
12711272
12721273 fn item_generics_num_lifetimes ( & self , def_id : DefId ) -> usize {
0 commit comments