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
AtclauseOrder: Falsely ignores method with annotation #9941
Comments
checkstyle/src/main/java/com/puppycrawl/tools/checkstyle/checks/javadoc/AtclauseOrderCheck.java Lines 267 to 277 in 13481f2
Issue is method returns the annotation definition instead of the method definition. The code wrongly believes we are looking at an annotation instead of method.
As seen in structure, getting the parent on the block just gives us the annotation and should skip that and the modifiers to give us the method definition. |
rnveach
changed the title
AtclauseOrder: Ignore method with annotation.
AtclauseOrder: Falsely ignores method with annotation
Apr 27, 2021
I am on it. |
Vyom-Yadav
added a commit
to Vyom-Yadav/checkstyle
that referenced
this issue
Apr 27, 2021
This was referenced Apr 27, 2021
Vyom-Yadav
added a commit
to Vyom-Yadav/checkstyle
that referenced
this issue
Apr 28, 2021
Vyom-Yadav
added a commit
to Vyom-Yadav/checkstyle
that referenced
this issue
Jun 7, 2021
Vyom-Yadav
added a commit
to Vyom-Yadav/checkstyle
that referenced
this issue
Jun 7, 2021
romani
pushed a commit
that referenced
this issue
Jun 12, 2021
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Identified at #9939
Method without annotation prints 2 violations while one with annotation prints none.
Method annotations should not play into this check's behavior and I expect the same violations between both examples.
The text was updated successfully, but these errors were encountered: