diff --git a/pmd/etc/changelog.txt b/pmd/etc/changelog.txt index 012983693a..b9b929ab96 100644 --- a/pmd/etc/changelog.txt +++ b/pmd/etc/changelog.txt @@ -1,6 +1,7 @@ ????? ??, 2013 - 5.0.3: Fixed bug 968: Issues with JUnit4 @Test annotation with expected exception (Thanks to Yiannis Paschalidis) +Fixed bug 975: false positive in ClassCastExceptionWithToArray Fixed bug 976: UselessStringValueOf wrong when appending character arrays Fixed bug 977: MisplacedNullCheck makes false positives Fixed bug 984: Cyclomatic complexity should treat constructors like methods diff --git a/pmd/src/main/resources/rulesets/java/basic.xml b/pmd/src/main/resources/rulesets/java/basic.xml index d22ecfcf88..9a23eae381 100644 --- a/pmd/src/main/resources/rulesets/java/basic.xml +++ b/pmd/src/main/resources/rulesets/java/basic.xml @@ -297,7 +297,7 @@ in a ClassCastException. + + + #975 false positive in ClassCastExceptionWithToArray + 0 + parms = new java.util.ArrayList(); + // public T QueryRunner.query(String sql, ResultSetHandler rsh, Object... params) + String result = (String) qr.query( sql, new ScalarHandler(), parms.toArray() ); + } +} + ]]> +