-
Notifications
You must be signed in to change notification settings - Fork 12.7k
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
Deprecated attributes do not apply to macro-expanded items #57679
Comments
I believe this is intentional; the attribute is applied to the macro call as opposed to the expansion thereof. cc @petrochenkov @rust-lang/lang |
Yes, attributes applied to macro calls are eliminated during expansion of the macro. |
What are the attributes that do have an effect on the macro call? |
Also, something like |
…enkov add applicability to remaining suggestions Fixes rust-lang#50723. I noticed that the suggestion methods on `DiagnosticBuilder` weren't actually deprecated due to rust-lang#57679. This PR deprecates them properly and fixes the remaining usages. There's also a PR for clippy at rust-lang/rust-clippy#3667.
The Is it possible it was overlooked when #50723 was fixed? |
I did a quick bisect, and this was fixed by #87296. Closing. |
Example at: https://play.rust-lang.org/?version=stable&mode=debug&edition=2018&gist=fc72706e6b3151479a1a454611827c50
I expected the deprecation lint to be fired on use of the
wrapped
function. If this is intentional behavior, I would expect a warning that the deprecated attribute is meaningless in that position.The text was updated successfully, but these errors were encountered: