Skip to content

fix self check in equals of Type#3995

Merged
filiphr merged 1 commit intomapstruct:mainfrom
hduelme:fix-self-check-in-equals-of-Type
Feb 14, 2026
Merged

fix self check in equals of Type#3995
filiphr merged 1 commit intomapstruct:mainfrom
hduelme:fix-self-check-in-equals-of-Type

Conversation

@hduelme
Copy link
Contributor

@hduelme hduelme commented Feb 11, 2026

While investigating #3994, I noticed that in Type.equals, hasExtendsBound() and hasSuperBound() are compared to themselves, which always evaluates to true.

As far as I can tell, equals is currently only used for Map comparisons. Nevertheless, this behavior seems wrong.

@filiphr filiphr merged commit 15312d6 into mapstruct:main Feb 14, 2026
5 checks passed
@filiphr filiphr added the bug label Feb 14, 2026
@filiphr filiphr added this to the 1.7.0.Beta2 milestone Feb 14, 2026
@filiphr
Copy link
Member

filiphr commented Feb 14, 2026

Thanks @hduelme

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants