Ignore other PredicateKind
s in rustdoc auto trait finder
Fixes #92073 There's not really anything we can do with them, and they're causing ICEs. I'm not using a wildcard match, as we should check that any new `PredicateKind`s are handled properly by rustdoc.
This commit is contained in:
parent
7abab1efb2
commit
d31f7f1097
1 changed files with 11 additions and 1 deletions
|
@ -839,7 +839,17 @@ impl<'tcx> AutoTraitFinder<'tcx> {
|
|||
_ => return false,
|
||||
}
|
||||
}
|
||||
_ => panic!("Unexpected predicate {:?} {:?}", ty, predicate),
|
||||
// There's not really much we can do with these predicates -
|
||||
// we start out with a `ParamEnv` with no inference variables,
|
||||
// and these don't correspond to adding any new bounds to
|
||||
// the `ParamEnv`.
|
||||
ty::PredicateKind::WellFormed(..)
|
||||
| ty::PredicateKind::ObjectSafe(..)
|
||||
| ty::PredicateKind::ClosureKind(..)
|
||||
| ty::PredicateKind::Subtype(..)
|
||||
| ty::PredicateKind::ConstEvaluatable(..)
|
||||
| ty::PredicateKind::Coerce(..)
|
||||
| ty::PredicateKind::TypeWellFormedFromEnv(..) => {}
|
||||
};
|
||||
}
|
||||
true
|
||||
|
|
Loading…
Add table
Reference in a new issue