[light classes] avoid resolve in equals

^KTIJ-21209
This commit is contained in:
Dmitry Gridin
2022-02-23 11:13:15 +07:00
parent 8811f62300
commit 261cac7514
2 changed files with 2 additions and 4 deletions
@@ -137,8 +137,7 @@ internal abstract class KtUltraLightMethod(
override fun equals(other: Any?): Boolean = other === this ||
other is KtUltraLightMethod &&
other.methodIndex == methodIndex &&
super.equals(other) &&
other.delegate == delegate
super.equals(other)
override fun hashCode(): Int = super.hashCode().times(31).plus(methodIndex.hashCode())
@@ -155,8 +155,7 @@ open class KtLightMethodImpl protected constructor(
other.javaClass == javaClass &&
other.memberIndex == memberIndex &&
other.containingClass == containingClass &&
other.lightMemberOrigin == lightMemberOrigin &&
other.dummyDelegate == dummyDelegate
other.lightMemberOrigin == lightMemberOrigin
override fun hashCode(): Int = name.hashCode()
.times(31).plus(containingClass.hashCode())