-
Notifications
You must be signed in to change notification settings - Fork 13.5k
Port #[ignore]
to the new attribute parsing infrastructure
#143238
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
base: master
Are you sure you want to change the base?
Conversation
☔ The latest upstream changes (presumably #143287) made this pull request unmergeable. Please resolve the merge conflicts. |
fa1eb67
to
0668ae9
Compare
rustbot has assigned @petrochenkov. Use |
Some changes occurred in compiler/rustc_attr_parsing Some changes occurred in compiler/rustc_passes/src/check_attr.rs Some changes occurred in compiler/rustc_attr_data_structures |
^ Rebased on master |
|
☔ The latest upstream changes (presumably #143459) made this pull request unmergeable. Please resolve the merge conflicts. |
0668ae9
to
9865738
Compare
^ @jdonszelmann rebased |
span: cx.attr_span, | ||
reason: match args { | ||
ArgParser::NoArgs => None, | ||
ArgParser::NameValue(name_value) => name_value.value_as_str(), |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should I guess error when it's not a string right? Not ignore it. If it didn't error before that might be a breaking change so we could do a warning first. @oli-obk could you help with some intuition for whether introducing a new error for something like this is acceptable despite being breaking?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Emitting the same lint as below wouldn't be so bad
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@jdonszelmann Good spot, thanks! Fixed
Also added a test case for it to the ever growing malformed-attrs.rs test
Signed-off-by: Jonathan Brouwer <[email protected]>
9865738
to
2d8ffff
Compare
@rustbot ready |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@bors r+ rollup
@bors r+ rollup |
…donszelmann Port `#[ignore]` to the new attribute parsing infrastructure Ports `ignore` to the new attribute parsing infrastructure for rust-lang#131229 (comment) This PR duplicates a change from rust-lang#143237 Draft until that one is merged
Rollup of 6 pull requests Successful merges: - #143238 (Port `#[ignore]` to the new attribute parsing infrastructure) - #143441 (Stop using `Key` trait unnecessarily) - #143478 (Miri subtree update) - #143486 (remove armv5te-unknown-linux-gnueabi target maintainer) - #143489 (Complete rustc_ast::mut_visit for spans.) - #143494 (Remove yields_in_scope from the scope tree.) r? `@ghost` `@rustbot` modify labels: rollup
Ports
ignore
to the new attribute parsing infrastructure for #131229 (comment)This PR duplicates a change from #143237
Draft until that one is merged