diff options
| author | bowlerman <oskar@goldhahn.info> | 2023-01-06 02:29:37 +0100 |
|---|---|---|
| committer | bowlerman <oskar@goldhahn.info> | 2023-01-10 03:04:28 +0100 |
| commit | f75eb24f4f397594604da304b3a1f7f11e1bea49 (patch) | |
| tree | 5745663a3a4c7fc783e737b78254008cb8ed2a23 /compiler/rustc_trait_selection | |
| parent | 3254bef9a79bd762b8cece2078abe168cb29ccb1 (diff) | |
remove E0280 and ICE instead
Diffstat (limited to 'compiler/rustc_trait_selection')
| -rw-r--r-- | compiler/rustc_trait_selection/src/traits/error_reporting/mod.rs | 18 |
1 files changed, 11 insertions, 7 deletions
diff --git a/compiler/rustc_trait_selection/src/traits/error_reporting/mod.rs b/compiler/rustc_trait_selection/src/traits/error_reporting/mod.rs index 9c098e1a2fc..5f06c4d8282 100644 --- a/compiler/rustc_trait_selection/src/traits/error_reporting/mod.rs +++ b/compiler/rustc_trait_selection/src/traits/error_reporting/mod.rs @@ -1102,15 +1102,19 @@ impl<'tcx> TypeErrCtxtExt<'tcx> for TypeErrCtxt<'_, 'tcx> { } ty::PredicateKind::Clause(ty::Clause::RegionOutlives(..)) - | ty::PredicateKind::Clause(ty::Clause::Projection(..)) | ty::PredicateKind::Clause(ty::Clause::TypeOutlives(..)) => { - let predicate = self.resolve_vars_if_possible(obligation.predicate); - struct_span_err!( - self.tcx.sess, + span_bug!( span, - E0280, - "the requirement `{}` is not satisfied", - predicate + "outlives clauses should not error outside borrowck. obligation: `{:?}`", + obligation + ) + } + + ty::PredicateKind::Clause(ty::Clause::Projection(..)) => { + span_bug!( + span, + "projection clauses should be implied from elsewhere. obligation: `{:?}`", + obligation ) } |
