HashableK
public protocol HashableK : EquatableK
EquatableK provides capabilities to compute a hash value at the kind level.
-
Hashes the essential components of a value wrapped by this kind, provided that the wrapped type conforms to
Hashable
.Implementations of this method must obey the following laws:
Coherence with equality
eq(fa1, fa2) -> fa1.hashValue == fa2.hashValue
Declaration
Swift
static func hash<A>(_ fa: Kind<Self, A>, into hasher: inout Hasher) where A : Hashable
Parameters
fa
A value wrapped by this kind.
hasher
The hasher to use when combining the components of this instance.