We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent f7c0557 commit 672f58cCopy full SHA for 672f58c
src/main/java/com/google/devtools/build/lib/collect/nestedset/Depset.java
@@ -611,4 +611,17 @@ public static boolean setDepthLimit(int newLimit) {
611
// The effective default value comes from the --nested_set_depth_limit
612
// flag in NestedSetOptionsModule, which overrides this.
613
private static final AtomicInteger depthLimit = new AtomicInteger(3500);
614
+
615
+ // Delegate equality to the underlying NestedSet. Otherwise, it's possible to create multiple
616
+ // Depset instances wrapping the same NestedSet that aren't equal to each other.
617
618
+ @Override
619
+ public int hashCode() {
620
+ return set.hashCode();
621
+ }
622
623
624
+ public boolean equals(Object other) {
625
+ return other instanceof Depset && set.equals(((Depset) other).set);
626
627
}
0 commit comments