瀏覽代碼

Implement hashCode for MultiType.

To honour the Object.equals contract.
tags/rel_3_23_0_ga
nickl- 6 年之前
父節點
當前提交
049879f903
共有 1 個檔案被更改,包括 8 行新增0 行删除
  1. 8
    0
      src/main/javassist/bytecode/analysis/MultiType.java

+ 8
- 0
src/main/javassist/bytecode/analysis/MultiType.java 查看文件

@@ -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…
取消
儲存