PMD Changelog

New in version 5.1.0

February 12th, 2014
  • This version adds support for Java 1.8, PLSQL, and Apache Velocity.

New in version 5.0.5 (August 14th, 2013)

  • This is a maintenance release with many bugfixes.

New in version 5.0.4 (May 2nd, 2013)

  • This is a maintenance release with many bugfixes.

New in version 5.0.3 (April 6th, 2013)

  • This is a maintenance release with many bugfixes.

New in version 5.0.1 (December 5th, 2012)

  • Fixed bug 820: False+ AvoidReassigningParameters
  • Fixed bug 1008: pmd-5.0.0: ImmutableField false positive on self-inc/dec
  • Fixed bug 1009: pmd-5.0.0: False + UselessParentheses
  • Fixed bug 1003: newline characters stripped from CPD data in PMD 5.0.0
  • Fixed bug 1001: InsufficientStringBufferDeclaration fails to parse hex
  • Fixed bug 522: InefficientStringBuffering bug false +
  • Fixed bug 953: String.InefficientStringBuffering false +
  • Fixed bug 981: Unable to parse Fixed bug 1010: pmd: parsing of generic method call with super fails
  • Fixed bug 996: pmd-4.2.6: MissingBreakInSwitch fails to report violation
  • Fixed bug 993: Invalid NPath calculation in return statement. Thanks to Prabhjot Singh for the patch.
  • Fixed bug 1023: c/c++ \ as a continuation character not supported
  • Fixed bug 1033: False+ : SingularField
  • Fixed bug 1025: Regression of Crash in PMDTask due to multithreading (Eclipse and Java 1.5)
  • Fixed bug 1017: Type resolution very slow for big project. Thanks to Roman for the patch.
  • Fixed bug 1036: Documentation: default threshold values removed from v5.0 Fixed bug 1035: UseObjectForClearerAPI has misspelled message
  • Fixed bug 1031: false DontImportJavaLang
  • Fixed bug 1034: UseConcurrentHashMap flags calls to methods that return Map
  • Fixed bug 1006: Problem with implementation of getPackageNameImage method Fixed bug 1014: AvoidLiteralsInIfCondition must NOT consider null
  • Fixed bug 1013: jnlp link for CPD is wrong
  • PMD Command Line Changes:
  • Improved command line interface (CLI) parsing using JCommander. Note: this breaks compatibility, but should be easy to fix.
  • With "-d" you specify nowtThe source files / source directory to be scanned.
  • With "-f" you select the report format (like text, html, ...)
  • With "-R" you select the rulesets to be used.
  • Example: pmd -d c:\data\pmd\pmd\test-data\Unused1.java -f xml -R rulesets/java/unusedcode.xml
  • Improved JSP parser to be less strict with not valid XML documents (like HTML). Thanks to Victor Bucutea.
  • Fixed bgastviewer not working. Thanks to Victor Bucutea.
  • Improved CPD: Support in CPD for IgnoreAnnotations and SuppressWarnings("CPD-START"). Thanks to Matthew Short.
  • Fixed C# support for CPD - thanks to TIOBE Software.
  • New Ecmascript rules: Basic ruleset: AvoidTrailingComma

New in version 5.0.0 (May 2nd, 2012)

  • This is a major version of PMD supporting additional languages and new rules.
  • The supported languages are Java, JavaScript, XML, XSL, and JSP. Many bugs have been fixed and new rules added.
  • The internal refactoring breaks compatibility with previous versions, but adds generic support for additional languages.
  • The maven coordinates have also been changed: net.sourceforge.pmd:pmd.

New in version 4.2.6 (September 20th, 2011)

  • This version includes bugfixes to existing rules.
  • It has modified (and hopefully fixed) the CPD algorithm.
  • The JSP/JSF parser can now parse Unicode input.
  • The JSP/JSP parser can now handle ... tags.
  • The AST HtmlScript node contains the content.
  • Ecmascript has been added as a supported language for CPD.

New in version 4.2.5 (February 9th, 2009)

  • This release includes bugfixes to existing rules, the new AvoidThrowingNewInstanceOfSameException rule in strictexception.xml, and the new android.xml ruleset for new rules specific to the Android platform.

New in version 4.2.3 (August 31st, 2008)

  • JavaCC generated artifacts updated to JavaCC 4.1d1
  • Java grammar enhanced to include AnnotationMethodDeclaration as parent node of method related children of AnnotationTypeMemberDeclaration Fixes for exclude-pattern Updates to RuleChain to honor RuleSet exclude-pattern Upgrading UselessOperationOnImmutable to detect more use cases, especially on String and fix false positives Fixed bug 1988829 - Violation reported without source file name (actually a fix to ConsecutiveLiteralAppends) Fixed bug 1989814 - false +: ConsecutiveLiteralAppends Fixed bug 1977230 - false positive: UselessOverridingMethod Fixed bug 1998185 - BeanMembersShouldSerialize vs @SuppressWarnings("serial") Fixed bug 2002722 - false + in UseStringBufferForStringAppends Fixed bug 2056318 - False positive for AvoidInstantiatingObjectsInLoops Fixed bug 1977438 - False positive for UselessStringValueOf Fixed bug 2050064 - False + SuspiciousOctalEscape with backslash literal Fixed bug 1556594 - Wonky detection of NullAssignment Optimizations and false positive fixes in PreserveStackTrace @SuppressWarnings("all") disables all warnings All comment types are now stored in ASTCompilationUnit, not just formal ones Fixed false negative in UselessOverridingMethod Fixed handling of escape characters in UseIndexOfChar and AppendCharacterWithChar