Object comparison using '==', instead of 'equals()'
Reports code that uses
!= rather than
equals() to test for object equality.
Comparing objects using
!= is often a bug, because it compares objects by identity instead of equality. Comparisons to
null are not reported.
Number comparisons are reported by separate inspections.
After the quick-fix is applied:
Use the inspection settings to configure exceptions for this inspection.
Ignore '==' between enum variables
Ignore '==' between final class types without 'equals()' implementation
Ignore '==' between objects of a type with only 'private' constructors
IntelliJ IDEA 2023.3, Qodana for JVM 2023.3