Bug: defines equals and uses Object.hashCode()

org.eclipse.help.internal.base.BookmarkManager$Bookmark defines equals
and uses Object.hashCode()

This class overrides equals(Object), but does notoverride hashCode(),
and inherits the implementation of hashCode() from java.lang.Object
(which returnsthe identity hash code, an arbitrary value assigned to the
objectby the VM).  Therefore, the class is very likely to violate
theinvariant that equal objects must have equal hashcodes.

Rank: Troubling (14), confidence: High
Pattern: HE_EQUALS_USE_HASHCODE
Type: HE, Category: BAD_PRACTICE (Bad practice)

Change-Id: I62029adf5c51d1320638f501467da44d78cd3525
Signed-off-by: Carsten Hammer <carsten.hammer@t-online.de>
Reviewed-on: https://git.eclipse.org/r/c/platform/eclipse.platform.ua/+/173458
Tested-by: Platform Bot <platform-bot@eclipse.org>
Reviewed-by: Mickael Istria <mistria@redhat.com>
1 file changed