??-????-2020 - 6.28.0-SNAPSHOT
The PMD team is pleased to announce PMD 6.28.0-SNAPSHOT.
This is a minor release.
New and noteworthy
CPD’s AnyTokenizer has been improved
The AnyTokenizer is used for languages, that don’t have an own lexer/grammar based tokenizer. AnyTokenizer now handles string literals and end-of-line comments. Fortran, Perl and Ruby have been updated to use AnyTokenizer instead of their old custom tokenizer based on AbstractTokenizer. See #2758 for details.
AbstractTokenizer and the custom tokenizers of Fortran, Perl and Ruby are deprecated now.
Fixed Issues
- cpd
- pmd-java
- #2708: [java] False positive FinalFieldCouldBeStatic when using lombok Builder.Default
- #2738: [java] Custom rule with @ExhaustiveEnumSwitch throws NPE
- #2756: [java] TypeTestUtil fails with NPE for anonymous class
- #2759: [java] False positive in UnusedAssignment
- #2767: [java] IndexOutOfBoundsException when parsing an initializer BlockStatement
API Changes
Deprecated API
For removal
net.sourceforge.pmd.RuleViolationComparator
. UseRuleViolation#DEFAULT_COMPARATOR
instead.net.sourceforge.pmd.cpd.AbstractTokenizer
. Usenet.sourceforge.pmd.cpd.AnyTokenizer
instead.net.sourceforge.pmd.cpd.FortranTokenizer
. Was replaced by anAnyTokenizer
. UseFortranLanguage#getTokenizer
anyway.net.sourceforge.pmd.cpd.PerlTokenizer
. Was replaced by anAnyTokenizer
. UsePerlLanguage#getTokenizer
anyway.net.sourceforge.pmd.cpd.RubyTokenizer
. Was replaced by anAnyTokenizer
. UseRubyLanguage#getTokenizer
anyway.RuleReference#getOverriddenLanguage
andRuleReference#setLanguage
External Contributions
- #2735: [ci] Add github actions for a fast view of pr succeed/not - XenoAmess
- #2747: [java] Don’t trigger FinalFieldCouldBeStatic when field is annotated with lombok @Builder.Default - Ollie Abbey
- #2773: [java] issue-2738: Adding null check to avoid npe when switch case is default - Nimit Patel