Version 5.4.1 of the PMD Open Source Project, released December 4, 2015.

Feature Request and Improvements

  • CPD: New command line parameter –ignore-usings: Ignore using directives in C# when comparing text.

Modified Rules

  • java-comments/CommentRequired: New property serialVersionUIDCommentRequired which controls the comment requirements for serialVersionUID fields. By default, no comment is required for this field.

Pull Requests

  • #25: Added option to exclude C# using directives from CPD analysis
  • #72: Added capability in Java and JSP parser for tracking tokens.
  • #74: Fix rendering CommentDefaultAccessModifier description as code
  • #75: RuleSetFactory Performance Enhancement

Bugfixes

  • java-comments/CommentDefaultAccessModifier
    • #1430: CommentDefaultAccessModifier triggers on field annotated with @VisibleForTesting
  • java-comments/CommentRequired
    • #1434: CommentRequired raises violation on serialVersionUID field
  • java-design/UseNotifyAllInsteadOfNotify
    • #1438: UseNotifyAllInsteadOfNotify gives false positive
  • java-finalizers/AvoidCallingFinalize
    • #1440: NPE in AvoidCallingFinalize
  • java-imports/UnnecessaryFullyQualifiedName
    • #1436: UnnecessaryFullyQualifiedName false positive on clashing static imports with enums
  • java-junit/JUnitAssertionsShouldIncludeMessage
    • #1373: JUnitAssertionsShouldIncludeMessage is no longer compatible with TestNG
  • java-migrating/JUnit4TestShouldUseBeforeAnnotation
    • #1446: False positive with JUnit4TestShouldUseBeforeAnnotation when TestNG is used
  • java-naming/SuspiciousEqualsMethodName
    • #1431: SuspiciousEqualsMethodName false positive
  • java-optimizations/RedundantFieldInitializer
    • #1443: RedundantFieldInitializer: False positive for small floats
  • java-unnecessary/UselessQualifiedThis
    • #1422: UselessQualifiedThis: False positive with Java 8 Function
  • java-unusedcode/UnusedPrivateField
    • #1428: False positive in UnusedPrivateField when local variable hides member variable
  • General
    • #1425: Invalid XML Characters in Output
    • #1429: Java - Parse Error: Cast in return expression
    • #1441: PMD: Update documentation how to compile after modularization