@@ -7,9 +7,7 @@ use rustc_trait_selection::traits::error_reporting::TypeErrCtxtExt;
7
7
use rustc_trait_selection:: traits:: query:: {
8
8
normalize:: NormalizationResult , CanonicalAliasGoal , NoSolution ,
9
9
} ;
10
- use rustc_trait_selection:: traits:: {
11
- self , FulfillmentError , FulfillmentErrorCode , ObligationCause , ObligationCtxt , SelectionContext ,
12
- } ;
10
+ use rustc_trait_selection:: traits:: { self , ObligationCause , ScrubbedTraitError , SelectionContext } ;
13
11
use tracing:: debug;
14
12
15
13
pub ( crate ) fn provide ( p : & mut Providers ) {
@@ -29,8 +27,7 @@ fn normalize_canonicalized_projection_ty<'tcx>(
29
27
30
28
tcx. infer_ctxt ( ) . enter_canonical_trait_query (
31
29
& goal,
32
- |ocx : & ObligationCtxt < ' _ , ' tcx , FulfillmentError < ' tcx > > ,
33
- ParamEnvAnd { param_env, value : goal } | {
30
+ |ocx, ParamEnvAnd { param_env, value : goal } | {
34
31
debug_assert ! ( !ocx. infcx. next_trait_solver( ) ) ;
35
32
let selcx = & mut SelectionContext :: new ( ocx. infcx ) ;
36
33
let cause = ObligationCause :: dummy ( ) ;
@@ -50,7 +47,7 @@ fn normalize_canonicalized_projection_ty<'tcx>(
50
47
// that impl vars are constrained by the signature, for example).
51
48
if !tcx. sess . opts . actually_rustdoc {
52
49
for error in & errors {
53
- if let FulfillmentErrorCode :: Cycle ( cycle) = & error. code {
50
+ if let ScrubbedTraitError :: Cycle ( cycle) = & error {
54
51
ocx. infcx . err_ctxt ( ) . report_overflow_obligation_cycle ( cycle) ;
55
52
}
56
53
}
@@ -74,7 +71,7 @@ fn normalize_canonicalized_weak_ty<'tcx>(
74
71
75
72
tcx. infer_ctxt ( ) . enter_canonical_trait_query (
76
73
& goal,
77
- |ocx : & ObligationCtxt < ' _ , ' tcx > , ParamEnvAnd { param_env, value : goal } | {
74
+ |ocx, ParamEnvAnd { param_env, value : goal } | {
78
75
let obligations = tcx. predicates_of ( goal. def_id ) . instantiate_own ( tcx, goal. args ) . map (
79
76
|( predicate, span) | {
80
77
traits:: Obligation :: new (
@@ -100,7 +97,7 @@ fn normalize_canonicalized_inherent_projection_ty<'tcx>(
100
97
101
98
tcx. infer_ctxt ( ) . enter_canonical_trait_query (
102
99
& goal,
103
- |ocx : & ObligationCtxt < ' _ , ' tcx > , ParamEnvAnd { param_env, value : goal } | {
100
+ |ocx, ParamEnvAnd { param_env, value : goal } | {
104
101
let selcx = & mut SelectionContext :: new ( ocx. infcx ) ;
105
102
let cause = ObligationCause :: dummy ( ) ;
106
103
let mut obligations = vec ! [ ] ;
0 commit comments