hashCode() fixed for AbstractClassTypeConstructor

This commit is contained in:
Andrey Breslav
2014-06-19 15:01:00 +04:00
parent 27273deeda
commit 145358654b
@@ -59,9 +59,8 @@ public abstract class AbstractClassTypeConstructor implements TypeConstructor {
public static int hashCode(@NotNull TypeConstructor me) {
ClassifierDescriptor descriptor = me.getDeclarationDescriptor();
if (descriptor instanceof ClassDescriptor && !ErrorUtils.isError(descriptor)) {
ClassDescriptor classDescriptor = (ClassDescriptor) descriptor;
return DescriptorUtils.getFqName(classDescriptor).hashCode();
if (descriptor instanceof ClassDescriptor && hasMeaningfulFqName(descriptor)) {
return DescriptorUtils.getFqName(descriptor).hashCode();
}
return System.identityHashCode(me);
}