forked from phoedos/pmd
Fixed bug 1579615 - OverrideBothEqualsAndHashcode no longer throws an Exception on equals methods that don't have Object as a parameter type. Thanks to Wouter Zelle for the report and the fix!
git-svn-id: https://pmd.svn.sourceforge.net/svnroot/pmd/trunk@4707 51baf565-9d33-0410-a72c-fc3788e3496d
This commit is contained in:
@ -10,6 +10,7 @@ Fixed bug 1573591 - NonThreadSafeSingleton doesn't throw NPE when using this key
|
||||
Fixed bug 1371753 - UnnecessaryLocalBeforeReturn is now less aggressive in its reporting.
|
||||
Fixed bug 1566547 - Annotations with an empty MemberValueArrayInitializer are now parsed properly.
|
||||
Fixed bugs 1060761 / 1433119 & RFE 1196954 - CloseResource now takes an optional parameter to identify closure methods
|
||||
Fixed bug 1579615 - OverrideBothEqualsAndHashcode no longer throws an Exception on equals methods that don't have Object as a parameter type.
|
||||
Applied patch 1551189 - SingularField false + for initialization blocks
|
||||
Applied patch 1573981 - false + in CloneMethodMustImplementCloneable
|
||||
Applied patch 1574988 - false + in OverrideBothEqualsAndHashcode
|
||||
|
@ -73,7 +73,7 @@ public class OverrideBothEqualsAndHashcode extends AbstractRule {
|
||||
if (iFormalParams == 0 && node.hasImageEqualTo("hashCode")) {
|
||||
containsHashCode = true;
|
||||
nodeFound = node;
|
||||
} else if (iFormalParams == 1 && node.hasImageEqualTo("equals") && (paramName.equals("Object") || paramName.equals("java.lang.Object"))) {
|
||||
} else if (iFormalParams == 1 && node.hasImageEqualTo("equals") && ("Object".equals(paramName) || "java.lang.Object".equals(paramName))) {
|
||||
containsEquals = true;
|
||||
nodeFound = node;
|
||||
}
|
||||
|
@ -52,6 +52,7 @@
|
||||
</subsection>
|
||||
<subsection name="Contributors">
|
||||
<ul>
|
||||
<li>Wouter Zelle - Fixed bug in OverrideBothEqualsAndHashcode, wrote BrokenNullCheck rule, fixed a false positive in InefficientStringBuffering, fixed a false positive in NonThreadSafeSingleton, a nice patch to clean up some of the Ant task properties and fix a TextRenderer bug, rewrote PositionLiteralsFirstInComparisons in XPath, Renderer improvement suggestions, wrote NonThreadSafeSingleton rule, wrote DefaultPackage rule, worked thru ASTMethodDeclaration.isSyntacticallyX design, reported docs bug 1292689 for UnnecessaryLocalBeforeReturn, reported leftover ExceptionTypeChecking source file, rewrote UselessOverridingMethod in Java, UselessOverridingMethod rule, ProperLogger rule, nifty code to allow variables in XPath rules, externalInfoUrl data for all rules in basic and unusedcode rulesets, some very nifty XSLT, improvements to UseCorrectExceptionLogging, designed and implemented the "externalInfoUrl" feature in the rule definitions, fixed a devious bug in RuleSetFactory, AvoidPrintStackTrace, initial implementation of SimplifyConditional</li>
|
||||
<li>Aaron Optimizer Digulla - Tweaks to pmd.bat</li>
|
||||
<li>Peter Van de Voorde - Rewrote the 'create rule XML' functionality in the designer utility</li>
|
||||
<li>Josh Devins - Reported bug with annotation parsing</li>
|
||||
@ -61,7 +62,6 @@
|
||||
<li>George Thomas - Wrote AvoidRethrowingException rule</li>
|
||||
<li>Robert Simmons - Reported bug in optimizations package along with suggestions for fix</li>
|
||||
<li>Brian Remedios - display cleanup of CPD GUI, code cleanup of StringUtil and various rules, cleanup of rule designer, code cleanup of net.sourceforge.pmd.ant.Formatter.java, code improvements to Eclipse plugin, created AbstractPoorMethodCall and refactored UseIndexOfChar</li>
|
||||
<li>Wouter Zelle - Wrote BrokenNullCheck rule, fixed a false positive in InefficientStringBuffering, fixed a false positive in NonThreadSafeSingleton, a nice patch to clean up some of the Ant task properties and fix a TextRenderer bug, rewrote PositionLiteralsFirstInComparisons in XPath, Renderer improvement suggestions, wrote NonThreadSafeSingleton rule, wrote DefaultPackage rule, worked thru ASTMethodDeclaration.isSyntacticallyX design, reported docs bug 1292689 for UnnecessaryLocalBeforeReturn, reported leftover ExceptionTypeChecking source file, rewrote UselessOverridingMethod in Java, UselessOverridingMethod rule, ProperLogger rule, nifty code to allow variables in XPath rules, externalInfoUrl data for all rules in basic and unusedcode rulesets, some very nifty XSLT, improvements to UseCorrectExceptionLogging, designed and implemented the "externalInfoUrl" feature in the rule definitions, fixed a devious bug in RuleSetFactory, AvoidPrintStackTrace, initial implementation of SimplifyConditional</li>
|
||||
<li>Sven Jacob - Some fixes for the DFA layer.</li>
|
||||
<li>Max Tardiveau - A nice XML to HTML stylesheet for CPD.</li>
|
||||
<li>Ernst Reissner - reported IdempotentOperations bug, reported CloneThrowsCloneNotSupportedException bug, reported JDK 1.5 parsing bug, suggested InstantiationToGetClass, bug reports for UnusedPrivateField/CloseConnectionRule/ConstructorCallsOverridableMethodRule, and bug report and documentation suggestions for UseSingletonRule</li>
|
||||
|
Reference in New Issue
Block a user