[Capsule] Use provided hasher argument

This commit is contained in:
Michael Steindorfer committed 2022-08-09 17:20:28 +02:00
1 parent b2808c45bb
commit cf5310624b
1 file changed
+1 -1
+1 -1
View File
@@ -14,7 +14,7 @@ extension HashMap: Hashable where Value: Hashable {
public func hash(into hasher: inout Hasher) {
var commutativeHash = 0
for (key, value) in self {
var elementHasher = Hasher()
var elementHasher = hasher
elementHasher.combine(key)
elementHasher.combine(value)
commutativeHash ^= elementHasher.finalize()