Kaynağa Gözat

Implement hashCode for MultiType.

To honour the Object.equals contract.
tags/rel_3_23_0_ga
nickl- 6 yıl önce
ebeveyn
işleme
049879f903

+ 8
- 0
src/main/javassist/bytecode/analysis/MultiType.java Dosyayı Görüntüle

@@ -281,6 +281,14 @@ public class MultiType extends Type {

return resolved;
}
@Override
public int hashCode() {
if (resolved != null)
return resolved.hashCode();
return interfaces.keySet().hashCode();
}

public boolean equals(Object o) {
if (! (o instanceof MultiType))

Loading…
İptal
Kaydet