Hello,
I would like to propose a change of the default value of the legalTrailingCommentPattern from:
^\s*+[^\s]++$
to
^(\s*+[^\s]+)?$.
It allows using empty comments (very often used by developers to force a new line) when automatic code formatted is enabled.
I’ve prepared an example code to allow verification:
- class: https://github.com/agabrys/sonarqube-falsepositives/blob/master/src/main/java/biz/gabrys/agabrys/sonarqube/falsepositives/d20180809/TrailingCommentCheck.java
- project: https://github.com/agabrys/sonarqube-falsepositives
- build:
mvn clean package sonar
Cheers