MCPcopy Create free account
hub / github.com/antlr/codebuff / hashCodeImpl

Method hashCodeImpl

output/java_guava/1.4.16/Sets.java:1442–1450  ·  view source on GitHub ↗

An implementation for Set#hashCode().

(Set<?> s)

Source from the content-addressed store, hash-verified

1440
1441
1442 static int hashCodeImpl(Set<?> s) {
1443 int hashCode = 0;
1444 for (Object o : s) {
1445 hashCode += o != null ? o.hashCode() : 0;
1446 hashCode = ~~hashCode;
1447 // Needed to deal with unusual integer overflow in GWT.
1448 }
1449 return hashCode;
1450 }
1451
1452 /**
1453 * An implementation for {@link Set#equals(Object)}.

Callers 12

hashCodeMethod · 0.95
hashCodeMethod · 0.95
standardHashCodeMethod · 0.95
hashCodeMethod · 0.95
standardHashCodeMethod · 0.95
hashCodeMethod · 0.95
hashCodeMethod · 0.95
hashCodeMethod · 0.95
hashCodeMethod · 0.95
hashCodeMethod · 0.95
hashCodeMethod · 0.95
hashCodeMethod · 0.45

Calls 1

hashCodeMethod · 0.65

Tested by

no test coverage detected