diff --git a/src/librustdoc/clean/auto_trait.rs b/src/librustdoc/clean/auto_trait.rs index 5c09da90491d..272819ba2dd9 100644 --- a/src/librustdoc/clean/auto_trait.rs +++ b/src/librustdoc/clean/auto_trait.rs @@ -263,7 +263,7 @@ impl<'a, 'tcx, 'rcx> AutoTraitFinder<'a, 'tcx, 'rcx> { })); } ty::GenericParamDefKind::Type {..} => { - args.push(hir::GenericArg::Type(P(self.ty_param_to_ty(param.clone())))); + args.push(hir::GenericArg::Type(self.ty_param_to_ty(param.clone()))); } } } diff --git a/src/librustdoc/clean/mod.rs b/src/librustdoc/clean/mod.rs index 057e7f3ab843..3cc0745b195e 100644 --- a/src/librustdoc/clean/mod.rs +++ b/src/librustdoc/clean/mod.rs @@ -2150,7 +2150,7 @@ pub struct Arguments { pub values: Vec, } -impl<'a> Clean for (&'a [P], &'a [Spanned]) { +impl<'a> Clean for (&'a [hir::Ty], &'a [Spanned]) { fn clean(&self, cx: &DocContext) -> Arguments { Arguments { values: self.0.iter().enumerate().map(|(i, ty)| { @@ -2168,7 +2168,7 @@ impl<'a> Clean for (&'a [P], &'a [Spanned]) { } } -impl<'a> Clean for (&'a [P], hir::BodyId) { +impl<'a> Clean for (&'a [hir::Ty], hir::BodyId) { fn clean(&self, cx: &DocContext) -> Arguments { let body = cx.tcx.hir.body(self.1); @@ -2184,7 +2184,7 @@ impl<'a> Clean for (&'a [P], hir::BodyId) { } impl<'a, A: Copy> Clean for (&'a hir::FnDecl, A) - where (&'a [P], A): Clean + where (&'a [hir::Ty], A): Clean { fn clean(&self, cx: &DocContext) -> FnDecl { FnDecl { @@ -2926,7 +2926,7 @@ impl Clean for hir::Ty { } }); if let Some(ty) = type_.cloned() { - ty_substs.insert(ty_param_def, ty.into_inner().clean(cx)); + ty_substs.insert(ty_param_def, ty.clean(cx)); } else if let Some(default) = default.clone() { ty_substs.insert(ty_param_def, default.into_inner().clean(cx));