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

Replace doc_comments_and_attrs with collect_attrs #16073

Merged
merged 1 commit into from Dec 9, 2023

Conversation

HKalbasi
Copy link
Member

@HKalbasi HKalbasi commented Dec 9, 2023

fix #16063

I looked at the other usages of doc_comments_and_attrs and it seems all of them are prone to ignoring inner attributes. @Veykril should I replace all of those with collect_attrs and remove doc_comments_and_attrs (or even HasDocComments) entirely?

@rustbot rustbot added the S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. label Dec 9, 2023
@HKalbasi
Copy link
Member Author

HKalbasi commented Dec 9, 2023

I'm going to merge this for now. Will replace remaining usages of doc_comments_and_attrs in another PR if desired.

@bors r+

@bors
Copy link
Collaborator

bors commented Dec 9, 2023

📌 Commit 9337519 has been approved by HKalbasi

It is now in the queue for this repository.

@bors
Copy link
Collaborator

bors commented Dec 9, 2023

⌛ Testing commit 9337519 with merge 9d87a23...

@Veykril
Copy link
Member

Veykril commented Dec 9, 2023

We should replace the other ones as well, though the one in semantics needs special casing depending on whether we are working with inner attributes or not.

Also the issue here is actually just

   mod _test_inner {
        #![empty_attr]
      //^^^^^^^^^^^^^^ error: unresolved macro `empty_attr`
    }

the extern crate is irrelevant

@bors
Copy link
Collaborator

bors commented Dec 9, 2023

☀️ Test successful - checks-actions
Approved by: HKalbasi
Pushing 9d87a23 to master...

@bors bors merged commit 9d87a23 into rust-lang:master Dec 9, 2023
10 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
S-waiting-on-review Status: Awaiting review from the assignee but also interested parties.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Panic on inner attributes in presence of unresolved crate
4 participants