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 some attributes from being merged with others on reexports #108057

Merged
merged 4 commits into from
Feb 16, 2023

Conversation

GuillaumeGomez
Copy link
Member

@GuillaumeGomez GuillaumeGomez commented Feb 14, 2023

Final fix for #59368.

As discussed on zulip here, we need to clone the Attribute to be able to filter some parts of it. Then we need to go through the attributes to be able to only keep what we want (everything except a few attributes in short).

As for the second commit, when I wrote the test, I realized that the code to traverse all reexports one by one to collect all their attributes was not completely working so I fixed the few issues remaining.

r? @notriddle

@rustbot rustbot added S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. T-rustdoc Relevant to the rustdoc team, which will review and decide on the PR/issue. labels Feb 14, 2023
src/librustdoc/clean/mod.rs Outdated Show resolved Hide resolved
src/librustdoc/clean/mod.rs Outdated Show resolved Hide resolved
@rust-log-analyzer

This comment has been minimized.

@GuillaumeGomez
Copy link
Member Author

Updated, thanks for the ideas!

@rust-log-analyzer

This comment has been minimized.

@GuillaumeGomez
Copy link
Member Author

The last commit fixes the handling of reexports of #[doc(hidden)] items when the reexport doesn't have #[doc(inline)].

@notriddle
Copy link
Contributor

@bors r+

@bors
Copy link
Contributor

bors commented Feb 16, 2023

📌 Commit 374f798 has been approved by notriddle

It is now in the queue for this repository.

@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 Feb 16, 2023
bors added a commit to rust-lang-ci/rust that referenced this pull request Feb 16, 2023
…iaskrgr

Rollup of 7 pull requests

Successful merges:

 - rust-lang#106347 (More accurate spans for arg removal suggestion)
 - rust-lang#108057 (Prevent some attributes from being merged with others on reexports)
 - rust-lang#108090 (`if $c:expr { Some($r:expr) } else { None }` =>> `$c.then(|| $r)`)
 - rust-lang#108092 (note issue for feature(packed_bundled_libs))
 - rust-lang#108099 (use chars instead of strings where applicable)
 - rust-lang#108115 (Do not ICE on unmet trait alias bounds)
 - rust-lang#108125 (Add new people to the compiletest review rotation)

Failed merges:

r? `@ghost`
`@rustbot` modify labels: rollup
@bors bors merged commit 0412898 into rust-lang:master Feb 16, 2023
@rustbot rustbot added this to the 1.69.0 milestone Feb 16, 2023
@GuillaumeGomez GuillaumeGomez deleted the fix-reexport-attr-merge branch February 16, 2023 22:38
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. T-rustdoc Relevant to the rustdoc team, which will review and decide on the PR/issue.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants