Fix tests from rebase

This commit is contained in:
Matthew Jasper 2020-09-07 10:01:45 +01:00
parent 1db284ecb0
commit 022c148fcd
100 changed files with 584 additions and 480 deletions

View file

@ -1204,22 +1204,18 @@ impl<'cx, 'tcx> SelectionContext<'cx, 'tcx> {
if let ty::PredicateAtom::Trait(pred, _) = bound.skip_binders() {
let bound = ty::Binder::bind(pred.trait_ref);
if self.infcx.probe(|_| {
if let Ok(normalized_trait) = self.match_projection(
match self.match_projection(
obligation,
bound,
placeholder_trait_predicate.trait_ref,
) {
match normalized_trait {
None => true,
Some(normalized_trait)
if distinct_normalized_bounds.insert(normalized_trait) =>
{
true
}
_ => false,
Ok(None) => true,
Ok(Some(normalized_trait))
if distinct_normalized_bounds.insert(normalized_trait) =>
{
true
}
} else {
false
_ => false,
}
}) {
return Some(idx);