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

rustc_ast: (Nested)MetaItem::check_name -> has_name #75043

Merged
merged 2 commits into from
Aug 4, 2020

Conversation

petrochenkov
Copy link
Contributor

@petrochenkov petrochenkov commented Aug 2, 2020

For consistency with Attribute::has_name which doesn't mark the attribute as used either.

Replace all uses of check_name with has_name outside of rustc, only rustc needs to mark attributes as used.

cc #74932
r? @nnethercote

@rust-highfive rust-highfive added the S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. label Aug 2, 2020
@nnethercote
Copy link
Contributor

Why do we not have to track usage for MetaItem and NestedMetaItem? Is it worth a comment in the code explaining this?

Also, #74932 will still be relevant after this lands, right? It will just be smaller and simpler.

r=me once the extra comment or two has been added. Thanks for doing this.

@petrochenkov petrochenkov added S-waiting-on-author Status: This is awaiting some action (such as code changes or more information) from the author. and removed S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. labels Aug 3, 2020
For consistency with `Attribute::has_name` which doesn't mark the attribute as used either.

Replace all uses of `check_name` with `has_name` outside of rustc
@petrochenkov
Copy link
Contributor Author

@bors r=nnethercote

@bors
Copy link
Contributor

bors commented Aug 3, 2020

📌 Commit 05f414b has been approved by nnethercote

@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-author Status: This is awaiting some action (such as code changes or more information) from the author. labels Aug 3, 2020
JohnTitor added a commit to JohnTitor/rust that referenced this pull request Aug 3, 2020
rustc_ast: `(Nested)MetaItem::check_name` -> `has_name`

For consistency with `Attribute::has_name` which doesn't mark the attribute as used either.

Replace all uses of `check_name` with `has_name` outside of rustc, only rustc needs to mark attributes as used.

cc rust-lang#74932
r? @nnethercote
bors added a commit to rust-lang-ci/rust that referenced this pull request Aug 4, 2020
Rollup of 8 pull requests

Successful merges:

 - rust-lang#74759 (add `unsigned_abs` to signed integers)
 - rust-lang#75043 (rustc_ast: `(Nested)MetaItem::check_name` -> `has_name`)
 - rust-lang#75056 (Lint path statements to suggest using drop when the type needs drop)
 - rust-lang#75081 (Fix logging for rustdoc)
 - rust-lang#75083 (Do not trigger `unused_braces` for `while let`)
 - rust-lang#75084 (Stabilize Ident::new_raw)
 - rust-lang#75103 (Disable building rust-analyzer on riscv64)
 - rust-lang#75106 (Enable docs on in the x86_64-unknown-linux-musl manifest)

Failed merges:

r? @ghost
@bors
Copy link
Contributor

bors commented Aug 4, 2020

⌛ Testing commit 05f414b with merge 60c2e8d...

@bors bors merged commit 262fce4 into rust-lang:master Aug 4, 2020
@cuviper cuviper added this to the 1.47.0 milestone May 2, 2024
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.

5 participants