@@ -36,7 +36,10 @@ use crate::traits::query::{
3636 OutlivesBound ,
3737} ;
3838use crate :: traits:: specialization_graph;
39- use crate :: traits:: { self , ImplSource } ;
39+ use crate :: traits:: {
40+ CanonicalChalkEnvironmentAndGoal , CodegenObligationError , EvaluationResult , ImplSource ,
41+ ObjectSafetyViolation , ObligationCause , OverflowError , WellFormedLoc ,
42+ } ;
4043use crate :: ty:: fast_reject:: SimplifiedType ;
4144use crate :: ty:: layout:: ValidityRequirement ;
4245use crate :: ty:: query:: {
@@ -1278,7 +1281,7 @@ rustc_queries! {
12781281
12791282 query codegen_select_candidate(
12801283 key: ( ty:: ParamEnv <' tcx>, ty:: PolyTraitRef <' tcx>)
1281- ) -> Result <& ' tcx ImplSource <' tcx, ( ) >, traits :: CodegenObligationError > {
1284+ ) -> Result <& ' tcx ImplSource <' tcx, ( ) >, CodegenObligationError > {
12821285 cache_on_disk_if { true }
12831286 desc { |tcx| "computing candidate for `{}`" , key. 1 }
12841287 }
@@ -1299,7 +1302,7 @@ rustc_queries! {
12991302 desc { |tcx| "building specialization graph of trait `{}`" , tcx. def_path_str( trait_id) }
13001303 cache_on_disk_if { true }
13011304 }
1302- query object_safety_violations( trait_id: DefId ) -> & ' tcx [ traits :: ObjectSafetyViolation ] {
1305+ query object_safety_violations( trait_id: DefId ) -> & ' tcx [ ObjectSafetyViolation ] {
13031306 desc { |tcx| "determining object safety of trait `{}`" , tcx. def_path_str( trait_id) }
13041307 }
13051308 query check_is_object_safe( trait_id: DefId ) -> bool {
@@ -1837,8 +1840,7 @@ rustc_queries! {
18371840 }
18381841
18391842 /// A list of all traits in a crate, used by rustdoc and error reporting.
1840- /// NOTE: Not named just `traits` due to a naming conflict.
1841- query traits_in_crate( _: CrateNum ) -> & ' tcx [ DefId ] {
1843+ query traits( _: CrateNum ) -> & ' tcx [ DefId ] {
18421844 desc { "fetching all traits in a crate" }
18431845 separate_provide_extern
18441846 }
@@ -1952,12 +1954,12 @@ rustc_queries! {
19521954 /// `infcx.predicate_must_hold()` instead.
19531955 query evaluate_obligation(
19541956 goal: CanonicalPredicateGoal <' tcx>
1955- ) -> Result <traits :: EvaluationResult , traits :: OverflowError > {
1957+ ) -> Result <EvaluationResult , OverflowError > {
19561958 desc { "evaluating trait selection obligation `{}`" , goal. value. value }
19571959 }
19581960
19591961 query evaluate_goal(
1960- goal: traits :: CanonicalChalkEnvironmentAndGoal <' tcx>
1962+ goal: CanonicalChalkEnvironmentAndGoal <' tcx>
19611963 ) -> Result <
19621964 & ' tcx Canonical <' tcx, canonical:: QueryResponse <' tcx, ( ) >>,
19631965 NoSolution
@@ -2127,8 +2129,8 @@ rustc_queries! {
21272129 /// all of the cases that the normal `ty::Ty`-based wfcheck does. This is fine,
21282130 /// because the `ty::Ty`-based wfcheck is always run.
21292131 query diagnostic_hir_wf_check(
2130- key: ( ty:: Predicate <' tcx>, traits :: WellFormedLoc )
2131- ) -> & ' tcx Option <traits :: ObligationCause <' tcx>> {
2132+ key: ( ty:: Predicate <' tcx>, WellFormedLoc )
2133+ ) -> & ' tcx Option <ObligationCause <' tcx>> {
21322134 arena_cache
21332135 eval_always
21342136 no_hash
0 commit comments