hashtables 1.3 → 1.3.1
raw patch · 3 files changed
+20/−8 lines, 3 filesdep ~hashabledep ~vectorPVP ok
version bump matches the API change (PVP)
Dependency ranges changed: hashable, vector
API changes (from Hackage documentation)
Files
- changelog.md +6/−0
- hashtables.cabal +4/−3
- src/Data/HashTable/ST/Basic.hs +10/−5
changelog.md view
@@ -1,5 +1,11 @@ # Hashtables changelog +## 1.3.1++Fix Noncanonical mappend definition warning.+Support more recent compilers.++ ## 1.3 Support Hashable 1.4. This new version of Hashable drops the Eq constraint, so the Eq constraint
hashtables.cabal view
@@ -1,6 +1,6 @@ Cabal-Version: 2.2 Name: hashtables-Version: 1.3+Version: 1.3.1 Synopsis: Mutable hash tables in the ST monad Homepage: http://github.com/gregorycollins/hashtables License: BSD-3-Clause@@ -22,7 +22,8 @@ GHC == 8.8.4 GHC == 8.10.7 GHC == 9.0.1- GHC == 9.2.1+ GHC == 9.2.4+ GHC == 9.4.2 Description: This package provides a couple of different implementations of mutable hash@@ -194,7 +195,7 @@ Build-depends: base >= 4.7 && <5, hashable >= 1.4 && < 1.5, primitive,- vector >= 0.7 && <0.13+ vector >= 0.7 && <0.14 if flag(portable) cpp-options: -DNO_C_SEARCH -DPORTABLE
src/Data/HashTable/ST/Basic.hs view
@@ -519,15 +519,19 @@ #if MIN_VERSION_base(4,9,0) instance Semigroup Slot where- (<>) = mappend+ (<>) = slotMappend #endif instance Monoid Slot where- mempty = Slot maxBound- (Slot x1) `mappend` (Slot x2) =- let !m = mask x1 maxBound- in Slot $! (complement m .&. x1) .|. (m .&. x2)+ mempty = Slot maxBound+#if ! MIN_VERSION_base(4,11,0)+ mappend = slotMappend+#endif +slotMappend :: Slot -> Slot -> Slot+slotMappend (Slot x1) (Slot x2) =+ let !m = mask x1 maxBound+ in Slot $! (complement m .&. x1) .|. (m .&. x2) ------------------------------------------------------------------------------ -- findSafeSlots return type@@ -841,3 +845,4 @@ let !i' = fromIntegral i return (Just (i', k, v)) {-# INLINE nextByIndex #-}+