Skip to content

Commit

Permalink
Address unused tuple struct fields in rustdoc
Browse files Browse the repository at this point in the history
  • Loading branch information
shepmaster committed Nov 27, 2023
1 parent 9f15a88 commit 765a713
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 6 deletions.
7 changes: 2 additions & 5 deletions src/librustdoc/clean/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1821,11 1821,8 @@ fn maybe_expand_private_type_alias<'tcx>(
}
_ => None,
});
if let Some(ct) = const_ {
args.insert(
param.def_id.to_def_id(),
SubstParam::Constant(clean_const(ct, cx)),
);
if let Some(_) = const_ {
args.insert(param.def_id.to_def_id(), SubstParam::Constant);
}
// FIXME(const_generics_defaults)
indices.consts = 1;
Expand Down
2 changes: 1 addition & 1 deletion src/librustdoc/clean/types.rs
Original file line number Diff line number Diff line change
Expand Up @@ -2546,7 2546,7 @@ pub(crate) enum TypeBindingKind {
pub(crate) enum SubstParam {
Type(Type),
Lifetime(Lifetime),
Constant(Constant),
Constant,
}

impl SubstParam {
Expand Down

0 comments on commit 765a713

Please sign in to comment.