Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

impl<S> Trait<Struct> for S {} blanket impl shows up multiple times in docs for Struct #81483

Closed
rodrimati1992 opened this issue Jan 28, 2021 · 1 comment
Labels
A-rustdoc-ui Area: Rustdoc UI (generated HTML) A-synthetic-impls Area: Synthetic impls, used by rustdoc to document auto traits and traits with blanket impls C-bug Category: This is a bug. T-rustdoc Relevant to the rustdoc team, which will review and decide on the PR/issue.

Comments

@rodrimati1992
Copy link
Contributor

rodrimati1992 commented Jan 28, 2021

I tried documenting this code with cargo doc:

pub struct Struct;

pub trait Trait<T> {}

impl<S> Trait<Struct> for S {}

I expected to see this happen: The impl<S> Trait<Struct> for S {} blanket impl appears only once in the docs for Struct

Instead, this happened: The blanket impl appears 23 times.

Picture of the blanket impls in the docs for `Struct`

Meta

rustc --version --verbose:

rustc 1.51.0-nightly (a2f8f6281 2021-01-27)
binary: rustc
commit-hash: a2f8f6281817d430e20726128b739d3c6708561c
commit-date: 2021-01-27
@rodrimati1992 rodrimati1992 added the C-bug Category: This is a bug. label Jan 28, 2021
@rodrimati1992 rodrimati1992 changed the title Blanket impl of Trait<Struct> shows up multiple times in docs for Struct impl<S> Trait<Struct> for S {} blanket impl shows up multiple times in docs for Struct Jan 29, 2021
@fmease fmease added T-rustdoc Relevant to the rustdoc team, which will review and decide on the PR/issue. A-rustdoc-ui Area: Rustdoc UI (generated HTML) A-synthetic-impls Area: Synthetic impls, used by rustdoc to document auto traits and traits with blanket impls and removed needs-triage-legacy labels Jan 23, 2024
@fmease
Copy link
Member

fmease commented Jan 23, 2024

No longer reproducible on stable or nightly. Likely same root cause as #96036. Probably fixed by #96091. Closing as completed.

@fmease fmease closed this as completed Jan 23, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-rustdoc-ui Area: Rustdoc UI (generated HTML) A-synthetic-impls Area: Synthetic impls, used by rustdoc to document auto traits and traits with blanket impls C-bug Category: This is a bug. T-rustdoc Relevant to the rustdoc team, which will review and decide on the PR/issue.
Projects
None yet
Development

No branches or pull requests

3 participants