@@ -61,7 +61,7 @@ rustc_queries! {
6161 /// predicate gets in the way of some checks, which are intended
6262 /// to operate over only the actual where-clauses written by the
6363 /// user.)
64- query predicates_of( _: DefId ) -> Lrc < ty:: GenericPredicates <' tcx> > { }
64+ query predicates_of( _: DefId ) -> & ' tcx ty:: GenericPredicates <' tcx> { }
6565
6666 query native_libraries( _: CrateNum ) -> Lrc <Vec <NativeLibrary >> {
6767 desc { "looking up the native libraries of a linked crate" }
@@ -166,11 +166,11 @@ rustc_queries! {
166166 /// equal to the `explicit_predicates_of` predicates plus the
167167 /// `inferred_outlives_of` predicates.
168168 query predicates_defined_on( _: DefId )
169- -> Lrc < ty:: GenericPredicates <' tcx> > { }
169+ -> & ' tcx ty:: GenericPredicates <' tcx> { }
170170
171171 /// Returns the predicates written explicit by the user.
172172 query explicit_predicates_of( _: DefId )
173- -> Lrc < ty:: GenericPredicates <' tcx> > { }
173+ -> & ' tcx ty:: GenericPredicates <' tcx> { }
174174
175175 /// Returns the inferred outlives predicates (e.g., for `struct
176176 /// Foo<'a, T> { x: &'a T }`, this would return `T: 'a`).
@@ -182,14 +182,14 @@ rustc_queries! {
182182 /// evaluate them even during type conversion, often before the
183183 /// full predicates are available (note that supertraits have
184184 /// additional acyclicity requirements).
185- query super_predicates_of( key: DefId ) -> Lrc < ty:: GenericPredicates <' tcx> > {
185+ query super_predicates_of( key: DefId ) -> & ' tcx ty:: GenericPredicates <' tcx> {
186186 desc { |tcx| "computing the supertraits of `{}`" , tcx. def_path_str( key) }
187187 }
188188
189189 /// To avoid cycles within the predicates of a single item we compute
190190 /// per-type-parameter predicates for resolving `T::AssocTy`.
191191 query type_param_predicates( key: ( DefId , DefId ) )
192- -> Lrc < ty:: GenericPredicates <' tcx> > {
192+ -> & ' tcx ty:: GenericPredicates <' tcx> {
193193 no_force
194194 desc { |tcx| "computing the bounds for type parameter `{}`" , {
195195 let id = tcx. hir( ) . as_local_hir_id( key. 1 ) . unwrap( ) ;
@@ -264,7 +264,7 @@ rustc_queries! {
264264
265265 Other {
266266 /// Maps from an impl/trait def-id to a list of the def-ids of its items
267- query associated_item_def_ids( _: DefId ) -> Lrc < Vec < DefId >> { }
267+ query associated_item_def_ids( _: DefId ) -> & ' tcx [ DefId ] { }
268268
269269 /// Maps from a trait item to the trait item "descriptor"
270270 query associated_item( _: DefId ) -> ty:: AssociatedItem { }
@@ -279,7 +279,7 @@ rustc_queries! {
279279 /// Maps a DefId of a type to a list of its inherent impls.
280280 /// Contains implementations of methods that are inherent to a type.
281281 /// Methods in these implementations don't need to be exported.
282- query inherent_impls( _: DefId ) -> Lrc < Vec < DefId >> {
282+ query inherent_impls( _: DefId ) -> & ' tcx [ DefId ] {
283283 eval_always
284284 }
285285 }
@@ -361,7 +361,7 @@ rustc_queries! {
361361 }
362362
363363 Other {
364- query used_trait_imports( _: DefId ) -> Lrc < DefIdSet > { }
364+ query used_trait_imports( _: DefId ) -> & ' tcx DefIdSet { }
365365 }
366366
367367 TypeChecking {
@@ -373,7 +373,7 @@ rustc_queries! {
373373 }
374374
375375 BorrowChecking {
376- query borrowck( _: DefId ) -> Lrc < BorrowCheckResult > { }
376+ query borrowck( _: DefId ) -> & ' tcx BorrowCheckResult { }
377377
378378 /// Borrow checks the function body. If this is a closure, returns
379379 /// additional requirements that the closure's creator must verify.
@@ -385,7 +385,7 @@ rustc_queries! {
385385 /// Not meant to be used directly outside of coherence.
386386 /// (Defined only for `LOCAL_CRATE`.)
387387 query crate_inherent_impls( k: CrateNum )
388- -> Lrc < CrateInherentImpls > {
388+ -> & ' tcx CrateInherentImpls {
389389 eval_always
390390 desc { "all inherent impls defined in crate `{:?}`" , k }
391391 }
@@ -683,11 +683,11 @@ rustc_queries! {
683683 Codegen {
684684 query upstream_monomorphizations(
685685 k: CrateNum
686- ) -> Lrc < DefIdMap <Lrc < FxHashMap <SubstsRef <' tcx>, CrateNum >> >> {
686+ ) -> & ' tcx DefIdMap <FxHashMap <SubstsRef <' tcx>, CrateNum >> {
687687 desc { "collecting available upstream monomorphizations `{:?}`" , k }
688688 }
689689 query upstream_monomorphizations_for( _: DefId )
690- -> Option <Lrc < FxHashMap <SubstsRef <' tcx>, CrateNum > >> { }
690+ -> Option <& ' tcx FxHashMap <SubstsRef <' tcx>, CrateNum >> { }
691691 }
692692
693693 Other {
@@ -726,12 +726,12 @@ rustc_queries! {
726726
727727 TypeChecking {
728728 query implementations_of_trait( _: ( CrateNum , DefId ) )
729- -> Lrc < Vec < DefId >> {
729+ -> & ' tcx [ DefId ] {
730730 no_force
731731 desc { "looking up implementations of a trait in a crate" }
732732 }
733733 query all_trait_implementations( _: CrateNum )
734- -> Lrc < Vec < DefId >> {
734+ -> & ' tcx [ DefId ] {
735735 desc { "looking up all (?) trait implementations" }
736736 }
737737 }
@@ -756,19 +756,19 @@ rustc_queries! {
756756
757757 BorrowChecking {
758758 // Lifetime resolution. See `middle::resolve_lifetimes`.
759- query resolve_lifetimes( _: CrateNum ) -> Lrc < ResolveLifetimes > {
759+ query resolve_lifetimes( _: CrateNum ) -> & ' tcx ResolveLifetimes {
760760 desc { "resolving lifetimes" }
761761 }
762762 query named_region_map( _: DefIndex ) ->
763- Option <Lrc < FxHashMap <ItemLocalId , Region > >> {
763+ Option <& ' tcx FxHashMap <ItemLocalId , Region >> {
764764 desc { "looking up a named region" }
765765 }
766766 query is_late_bound_map( _: DefIndex ) ->
767- Option <Lrc < FxHashSet <ItemLocalId > >> {
767+ Option <& ' tcx FxHashSet <ItemLocalId >> {
768768 desc { "testing if a region is late bound" }
769769 }
770770 query object_lifetime_defaults_map( _: DefIndex )
771- -> Option <Lrc < FxHashMap <ItemLocalId , Lrc < Vec <ObjectLifetimeDefault >> >>> {
771+ -> Option <& ' tcx FxHashMap <ItemLocalId , Vec <ObjectLifetimeDefault >>> {
772772 desc { "looking up lifetime defaults for a region" }
773773 }
774774 }
@@ -786,7 +786,7 @@ rustc_queries! {
786786 eval_always
787787 desc { "fetching what a crate is named" }
788788 }
789- query item_children( _: DefId ) -> Lrc < Vec < Export <hir:: HirId >>> { }
789+ query item_children( _: DefId ) -> & ' tcx [ Export <hir:: HirId >] { }
790790 query extern_mod_stmt_cnum( _: DefId ) -> Option <CrateNum > { }
791791
792792 query get_lib_features( _: CrateNum ) -> Lrc <LibFeatures > {
0 commit comments