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
Issue #11885: Allow SuppressWarningHolder to suppress the violation with NameCheck #11889
Issue #11885: Allow SuppressWarningHolder to suppress the violation with NameCheck #11889
Conversation
a6cb1c5
to
f1f7275
Compare
Github, generate report |
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.
Ok to merge
I guess documentation is missing still.
Do either of these sound suitable?
or |
Let's use this |
f1f7275
to
24e2b28
Compare
@stoyanK7 , please resolve conflict |
24e2b28
to
28c0708
Compare
Github, generate site |
@@ -97,8 +97,8 @@ | |||
* </pre> | |||
* <p> | |||
* The general rule is that the argument of the {@code @SuppressWarnings} will be | |||
* matched against class name of the checker in lower case and without {@code Check} | |||
* suffix if present. | |||
* matched against class name of the checker in any letter case. Adding {@code check} |
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.
checker
I am assuming this is suppose to be check or module.
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.
That is correct.
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.
@stoyanK7 , please fix this typo "checker" -> "Check".
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.
Done!
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.
Checks are now passing too!
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.
@rnveach ping
28c0708
to
8ba68b7
Compare
8ba68b7
to
dc1c5a4
Compare
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.
My only remaining comment is there doesn't seem to be any examples showing "Name" and "NameCheck" and "NaMeChEcK" is supported.
Yeah, I only wrote
Original issue said only to mention it in words, without example. I can add an example if you really want one :) |
@romani can clarify if an example is needed |
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.
Example is not required, we already have enough examples.
Resolves #11885
Allows
SuppressWarningHolder
to suppress violations with NameCheck i.e@SuppressWarnings("checkstyle:constantnamecheck")
or@SuppressWarnings("checkstyle:ConstantNameCheck")
Diff Regression config: https://gist.githubusercontent.com/stoyanK7/73d7efde0efd9c6496ba95f0816ccb86/raw/0e0179ee0b4e193cb5faa8b5fcfa74a6bc1a46f0/config.xml