Avoid storing the ImplPolarity and Constness next to a TraitRef and use TraitPredicate instead
This commit is contained in:
parent
d161cc2071
commit
a848c4ba3f
11 changed files with 59 additions and 53 deletions
|
@ -508,9 +508,9 @@ crate fn to_pretty_impl_header(tcx: TyCtxt<'_>, impl_def_id: DefId) -> Option<St
|
|||
Vec::with_capacity(predicates.len() + types_without_default_bounds.len());
|
||||
|
||||
for (p, _) in predicates {
|
||||
if let Some(poly_trait_ref) = p.to_opt_poly_trait_ref() {
|
||||
if Some(poly_trait_ref.value.def_id()) == sized_trait {
|
||||
types_without_default_bounds.remove(poly_trait_ref.value.self_ty().skip_binder());
|
||||
if let Some(poly_trait_ref) = p.to_opt_poly_trait_pred() {
|
||||
if Some(poly_trait_ref.def_id()) == sized_trait {
|
||||
types_without_default_bounds.remove(poly_trait_ref.self_ty().skip_binder());
|
||||
continue;
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue