-
Bug
-
Resolution: Fixed
-
Minor
-
None
We have this line of code:
public boolean hasNext() { return cursor == EMPTY && entity != EMPTY; }
PMD xml report has these violations reported:
<violation beginline="216" endline="216" begincolumn="32" endcolumn="46" rule="CompareObjectsWithEquals" ruleset="Design Rules" package="com.myapplication.util.collections" class="SingleSet$SingleSetIterator" method="hasNext" externalInfoUrl="http://pmd.sourceforge.net/rules/design.html#CompareObjectsWithEquals" priority="3"> Use equals() to compare object references. </violation> <violation beginline="216" endline="216" begincolumn="51" endcolumn="65" rule="CompareObjectsWithEquals" ruleset="Design Rules" package="com.myapplication.util.collections" class="SingleSet$SingleSetIterator" method="hasNext" externalInfoUrl="http://pmd.sourceforge.net/rules/design.html#CompareObjectsWithEquals" priority="3"> Use equals() to compare object references. </violation>
Is reports 2 issues on the same line. Other begincolumn and other endcolumn.
In the UI it is only reported once.
And the total number of violations does not match with the actual number of violations.
- is duplicated by
-
JENKINS-12822 Java import of deprecated type not recognized as warning
- Resolved