Skip to content

Commit 1c1db36

Browse files
committed
more hashCode's
1 parent 5d35e05 commit 1c1db36

File tree

2 files changed

+10
-0
lines changed

2 files changed

+10
-0
lines changed

src/main/java/org/variantsync/diffdetective/gumtree/VariationDiffAdapter.java

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -29,4 +29,9 @@ protected VariationTreeAdapter<L> newInstance(VariationNode<?, L> node) {
2929
public DiffNode<L> getDiffNode() {
3030
return Cast.<VariationNode<?, L>, Projection<L>>unchecked(getVariationNode()).getBackingNode();
3131
}
32+
33+
@Override
34+
public int hashCode() {
35+
return getLabel().hashCode();
36+
}
3237
}

src/main/java/org/variantsync/diffdetective/gumtree/VariationTreeAdapter.java

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -115,4 +115,9 @@ public void setType(Type type) {
115115
public Tree deepCopy() {
116116
throw new UnsupportedOperationException();
117117
}
118+
119+
@Override
120+
public int hashCode() {
121+
return getLabel().hashCode();
122+
}
118123
}

0 commit comments

Comments
 (0)