1
Fork 0

Check #[diagnostic::do_not_recommend] for arguments

This commit adds a check that verifies that no arguments are passed to
`#[diagnostic::do_not_recommend]`. If we detect arguments we emit a warning.
This commit is contained in:
Georg Semmler 2024-10-23 07:48:57 +02:00
parent bfd02d8b36
commit ecb6fd8d3a
No known key found for this signature in database
GPG key ID: A87BCEE5205CE489
6 changed files with 91 additions and 2 deletions

View file

@ -357,6 +357,9 @@ passes_ignored_derived_impls =
passes_implied_feature_not_exist =
feature `{$implied_by}` implying `{$feature}` does not exist
passes_incorrect_do_not_recommend_args =
`#[diagnostic::do_not_recommend]` does not expect any arguments
passes_incorrect_do_not_recommend_location =
`#[diagnostic::do_not_recommend]` can only be placed on trait implementations