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

Prevent duplicated impl on foreign types #53801

Merged

Conversation

GuillaumeGomez
Copy link
Member

@rust-highfive rust-highfive added the S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. label Aug 29, 2018
@QuietMisdreavus
Copy link
Member

Is there a way we can reproduce this so we can test it? The change is small enough that it looks fine (though i wonder if there's a deeper issue causing those duplicates to get added in the first place) but i'm hesitant to take it on its own.

@QuietMisdreavus
Copy link
Member

(Closed by accident, oops...)

@GuillaumeGomez
Copy link
Member Author

The issue is actually "easy": the T represents multiple types, therefore, the current path duplicates check doesn't work since they're different T everytime.

Also for the test, the better one would be the UI one. I'm waiting for it to be merged before adding test for this fix. Do you want me to open an issue for it?

@QuietMisdreavus
Copy link
Member

Isn't there a way we can use a @count rule in a regular rustdoc test that could track this? It seems like a perfect fit for it.

@GuillaumeGomez
Copy link
Member Author

It is, just thought it wasn't a great idea.

@QuietMisdreavus
Copy link
Member

If you think you can get a better test in later on, then i guess it's fine.

@bors r+ rollup

@bors
Copy link
Contributor

bors commented Aug 31, 2018

📌 Commit 3b98571 has been approved by QuietMisdreavus

@bors bors added S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. and removed S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. labels Aug 31, 2018
kennytm added a commit to kennytm/rust that referenced this pull request Sep 1, 2018
…ype-impls, r=QuietMisdreavus

Prevent duplicated impl on foreign types

Fixes rust-lang#53689.

r? @QuietMisdreavus
bors added a commit that referenced this pull request Sep 1, 2018
Rollup of 9 pull requests

Successful merges:

 - #53076 (set cfg(rustdoc) when rustdoc is running on a crate)
 - #53622 (cleanup: Add main functions to some UI tests)
 - #53769 (Also link Clippy repo in the CONTRIBUTING.md file)
 - #53774 (Add rust-gdbgui script.)
 - #53781 (bench: libcore: fix build failure of any.rs benchmark (use "dyn Any"))
 - #53782 (Make Arc cloning mechanics clearer in module docs)
 - #53790 (Add regression test for issue #52060)
 - #53801 (Prevent duplicated impl on foreign types)
 - #53850 (Nuke the `const_to_allocation` query)
@bors bors merged commit 3b98571 into rust-lang:master Sep 1, 2018
@GuillaumeGomez GuillaumeGomez deleted the duplicated-foreign-type-impls branch September 1, 2018 22:26
kennytm added a commit to kennytm/rust that referenced this pull request Sep 12, 2018
…etMisdreavus

rustdoc: Remove generated blanket impls from trait pages

rust-lang#53801 only deduped the generated blanket impls but they shouldn't be displayed at all because the original blanket impl is already in the "Implementors" section. This also removes the impls from the sidebar.

Fixes rust-lang#53689

r? @QuietMisdreavus
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants