hashes 0.1.0.0 → 0.1.0.1
raw patch · 3 files changed
+17/−3 lines, 3 filesPVP ok
version bump matches the API change (PVP)
API changes (from Hackage documentation)
Files
- CHANGELOG.md +4/−0
- hashes.cabal +1/−1
- src/Data/Hash/FNV1.hs +12/−2
CHANGELOG.md view
@@ -1,5 +1,9 @@ # Revision history for the hashes package +## 0.1.0.1 -- 2021-09-30++* Support building with GHC-9.2.0-rc1+ ## 0.1.0.0 -- 2021-09-29 * First version. Released on an unsuspecting world.
hashes.cabal view
@@ -1,6 +1,6 @@ cabal-version: 2.4 name: hashes-version: 0.1.0.0+version: 0.1.0.1 synopsis: Hash functions Description: Efficient implementation of non-cryptographic hash functions homepage: https://github.com/larskuhtz/hs-hashes
src/Data/Hash/FNV1.hs view
@@ -197,7 +197,7 @@ 1# -> (# s, acc #) _ -> case readWord8OffAddr# addr i s of (# s1, w #) -> loop- ((p `timesWord#` acc) `xor#` w)+ ((p `timesWord#` acc) `xor#` word8ToWord# w) (i +# 1#) s1 @@ -230,10 +230,20 @@ 1# -> (# s, acc #) _ -> case readWord8OffAddr# addr i s of (# s1, w #) -> loop- (p `timesWord#` (acc `xor#` w))+ (p `timesWord#` (acc `xor#` word8ToWord# w)) (i +# 1#) s1 !(W# p) = fnvPrime {-# INLINE fnv1aPrimitive_ #-} +-- -------------------------------------------------------------------------- --+-- Backward compatibility++#if !MIN_VERSION_base(4,16,0)+-- | 'readWord8OffAddr#' returns 'Word#' for base < 4.16.0. So, there's no+-- need to convert it to 'Word#' down the road.+--+word8ToWord# :: Word# -> Word#+word8ToWord# a = a+#endif