License | BSD-style |
---|---|
Maintainer | Foundation |
Safe Haskell | None |
Language | Haskell2010 |
Foundation.Hashing
Contents
Description
Documentation
class Hashable a where Source #
Type with the ability to be hashed
Hashable doesn't have any specific rules, and it's made for raw speed. More specifically don't expect different type representing the same data to hash to the same value
hashMix (1 :: Integer) /= hashMix (1 :: Word8)
True
Minimal complete definition
Instances
Incremental Hashing state. Represent an hashing algorithm
the base primitive of this class is hashMix8
, append
mix a Word8 in the state
The class allow to define faster mixing function that works on bigger Word size and any unboxed array of any PrimType elements
Minimal complete definition
hashNew, hashNewParam, hashMix8, hashEnd
Specific methods
Sip State 1-3 (1 compression rounds, 3 digest rounds)