rspec/rules/S2162/java/comments-and-links.adoc

18 lines
1.0 KiB
Plaintext
Raw Normal View History

=== Rule replacement: RSPEC-2161
=== On 2014-10-15T21:50:59Z Freddy Mallet Wrote:
We're advising the opposite in the compliant solution of rule RSPEC-2097 @Ann. And we're doing that because 95% of the time, developers are using ``++instanceof++`` operator which is more readable than checking the equality of classes.
I guess this rule might remain valuable in some specific contexts but I would not activate it by default.
=== On 2014-10-16T15:44:56Z Ann Campbell Wrote:
\[~freddy.mallet] I've updated RSPEC-2097 because the old example was broken for child classes since the advice is to use the parent class' ``++equals++`` method for parent class fields and check child class fields in the child's ``++equals++`` method.
=== On 2014-10-16T16:36:20Z Ann Campbell Wrote:
FYI [~freddy.mallet], I followed, then reversed your advice and combined this with EQ_CHECK_FOR_OPERAND_NOT_COMPATIBLE_WITH_THIS instead since both rules look at symmetry.
=== On 2014-10-17T10:07:04Z Freddy Mallet Wrote:
Ok @Ann and I would merge this rule with RSPEC-2161