Prior to this commit, when there was a lot of entries in the ResolvableType.cache HashMap, getting a simple value could take a lot of time due to a lot of calls to ResolvableType.equals(). ResolvableType.equals() used this.type, getSource(), this.variableResolver.getSource() and this.componentType, but ResolvableType.hashCode() used only this.type.

With this commit, ResolvableType.hashCode() now uses the same fields than ResolvableType.equals().

Performances on the spring-resolvabletype-benchmark project: - 8000 us before this commit - 120 us with this commit

Issue: SPR-12122

Comment From: sdeleuze

Merged in master