rustdoc: Remove Sized bounds when cleaning foreign impl Trait
This commit is contained in:
parent
ac655d25c7
commit
32446f8db3
1 changed files with 8 additions and 0 deletions
|
|
@ -2770,6 +2770,14 @@ impl<'tcx> Clean<Type> for Ty<'tcx> {
|
|||
return None;
|
||||
};
|
||||
|
||||
if let Some(sized) = cx.tcx.lang_items().sized_trait() {
|
||||
if trait_ref.def_id() == sized {
|
||||
return None;
|
||||
}
|
||||
}
|
||||
|
||||
// FIXME(Manishearth) handle cases which aren't Sized
|
||||
|
||||
let bounds = bounds.predicates.iter().filter_map(|pred|
|
||||
if let ty::Predicate::Projection(proj) = *pred {
|
||||
let proj = proj.skip_binder();
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue