diff options
| author | Guillaume Gomez <guillaume1.gomez@gmail.com> | 2020-01-17 19:51:07 +0100 |
|---|---|---|
| committer | Guillaume Gomez <guillaume1.gomez@gmail.com> | 2020-01-17 19:51:07 +0100 |
| commit | 482dc77dee59dd44448973758980806bd63aa5a3 (patch) | |
| tree | 6d4f828fff5c557a490ae0c08de675745ce776f7 | |
| parent | 3094c3792bb0bffbaaa0688d02c970054c353d1f (diff) | |
| download | rust-482dc77dee59dd44448973758980806bd63aa5a3.tar.gz rust-482dc77dee59dd44448973758980806bd63aa5a3.zip | |
formatting
| -rw-r--r-- | src/librustdoc/clean/mod.rs | 40 |
1 files changed, 19 insertions, 21 deletions
diff --git a/src/librustdoc/clean/mod.rs b/src/librustdoc/clean/mod.rs index 0e9f363bec3..20a5a6c5498 100644 --- a/src/librustdoc/clean/mod.rs +++ b/src/librustdoc/clean/mod.rs @@ -2121,27 +2121,25 @@ impl Clean<Vec<Item>> for doctree::Impl<'_> { Some(DefKind::TyAlias) => Some(cx.tcx.type_of(did).clean(cx)), _ => None, }); - let make_item = |trait_: Option<Type>, for_: Type, items: Vec<Item>| { - Item { - name: None, - attrs: self.attrs.clean(cx), - source: self.whence.clean(cx), - def_id, - visibility: self.vis.clean(cx), - stability: cx.stability(self.id).clean(cx), - deprecation: cx.deprecation(self.id).clean(cx), - inner: ImplItem(Impl { - unsafety: self.unsafety, - generics: self.generics.clean(cx), - provided_trait_methods: provided.clone(), - trait_, - for_, - items, - polarity: Some(cx.tcx.impl_polarity(def_id).clean(cx)), - synthetic: false, - blanket_impl: None, - }), - } + let make_item = |trait_: Option<Type>, for_: Type, items: Vec<Item>| Item { + name: None, + attrs: self.attrs.clean(cx), + source: self.whence.clean(cx), + def_id, + visibility: self.vis.clean(cx), + stability: cx.stability(self.id).clean(cx), + deprecation: cx.deprecation(self.id).clean(cx), + inner: ImplItem(Impl { + unsafety: self.unsafety, + generics: self.generics.clean(cx), + provided_trait_methods: provided.clone(), + trait_, + for_, + items, + polarity: Some(cx.tcx.impl_polarity(def_id).clean(cx)), + synthetic: false, + blanket_impl: None, + }), }; if let Some(type_alias) = type_alias { ret.push(make_item(trait_.clone(), type_alias, items.clone())); |
