Skip to content

Commit 7131a15

Browse files
committed
Suppress AnnotationLocation checkstyle rule
This rule flags valid usages because it conflates annotated methods and annotated return types, considering that the `@Nullable` annotation should be on its own line. For example, the following fails: ``` @OverRide @nullable String getName() { ``` See gh-1132
1 parent d7db1a0 commit 7131a15

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

src/checkstyle/checkstyle-suppressions.xml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,8 @@
88

99
<!-- main -->
1010
<suppress files="[\\/]src[\\/]main[\\/]java[\\/]" checks="SpringMethodVisibility" />
11+
<!-- Ignore this check for @Nullable annotations -->
12+
<suppress files="[\\/]src[\\/]main[\\/]java[\\/]" checks="AnnotationLocation" />
1113

1214
<!-- tests -->
1315
<suppress files="[\\/]src[\\/]testFixtures[\\/]java[\\/]" checks="JavadocPackage|SpringJavadoc" />

0 commit comments

Comments
 (0)