-
Notifications
You must be signed in to change notification settings - Fork 13.1k
New issue
Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? # to your account
rustc_plugin: Remove Registry::register_attribute
#66344
Conversation
(rust_highfive has picked a reviewer for you, use r? to override) |
cc @SimonSapin @rust-lang/dev-tools |
659f502
to
cae9923
Compare
@petrochenkov Would you be ok with waiting a bit before landing this? The alternative only landed very recently, and upgrading the Rust version used in Servo is currently blocked on fixing some new warnings: servo/servo#24684 |
I’ve verified that removing I’m afraid the latter renders the lint ineffective since it relies on |
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.
Changes look good. I'm marking as blocked while Servo makes changes.
☔ The latest upstream changes (presumably #66366) made this pull request unmergeable. Please resolve the merge conflicts. |
Use `#![register_tool]` instead of `Registry::register_attribute` CC rust-lang/rust#66344, rust-lang/rust#66079
Use `#![register_tool]` instead of `Registry::register_attribute` CC rust-lang/rust#66344, rust-lang/rust#66079
Alright, Servo should be unblocked now: servo/servo#24750 |
cae9923
to
8575743
Compare
@bors r=matthewjasper |
📌 Commit 8575743 has been approved by |
…sper rustc_plugin: Remove `Registry::register_attribute` Legacy plugins cannot register inert attributes anymore. The preferred replacement is to use `register_tool` ([tracking issue](rust-lang#66079)). ```rust #![register_tool(servo)] #[servo::must_root] struct S; ``` The more direct replacement is `register_attribute` ([tracking issue](rust-lang#66080)) ```rust #![register_attr(must_root)] #[must_root] struct S; ``` , but it requires registering each attribute individually rather than registering the tool once, and is more likely to be removed rather than stabilized.
…sper rustc_plugin: Remove `Registry::register_attribute` Legacy plugins cannot register inert attributes anymore. The preferred replacement is to use `register_tool` ([tracking issue](rust-lang#66079)). ```rust #![register_tool(servo)] #[servo::must_root] struct S; ``` The more direct replacement is `register_attribute` ([tracking issue](rust-lang#66080)) ```rust #![register_attr(must_root)] #[must_root] struct S; ``` , but it requires registering each attribute individually rather than registering the tool once, and is more likely to be removed rather than stabilized.
Rollup of 11 pull requests Successful merges: - #65739 (Improve documentation of `Vec::split_off(...)`) - #66271 (syntax: Keep string literals in ABIs and `asm!` more precisely) - #66344 (rustc_plugin: Remove `Registry::register_attribute`) - #66381 (find_deprecation: deprecation attr may be ill-formed meta.) - #66395 (Centralize panic macro documentation) - #66456 (Move `DIAGNOSTICS` usage to `rustc_driver`) - #66465 (add missing 'static lifetime in docs) - #66466 (miri panic_unwind: fix hack for SEH platforms) - #66469 (Use "field is never read" instead of "field is never used") - #66471 (Add test for issue 63116) - #66477 (Clarify transmute_copy documentation example) Failed merges: r? @ghost
Legacy plugins cannot register inert attributes anymore.
The preferred replacement is to use
register_tool
(tracking issue).The more direct replacement is
register_attribute
(tracking issue), but it requires registering each attribute individually rather than registering the tool once, and is more likely to be removed rather than stabilized.