packages feed

vector-instances 3.4.2 → 3.4.3

raw patch · 3 files changed

+25/−4 lines, 3 filesPVP ok

version bump matches the API change (PVP)

API changes (from Hackage documentation)

+ Data.Vector.Instances: instance Data.Hashable.Class.Hashable a => Data.Hashable.Class.Hashable (Data.Vector.Strict.Vector a)
+ Data.Vector.Instances: instance Data.Hashable.Class.Hashable1 Data.Vector.Strict.Vector

Files

CHANGELOG.markdown view
@@ -1,3 +1,8 @@+3.4.3 [2025.06.01]+------------------+* Add `Hashable` and `Hashable1` instances for strict `Vector`s (when building+  with `vector-0.13.2.0` or later).+ 3.4.2 [2023.04.17] ------------------ * Remove unused dependency on `semigroups`.
src/Data/Vector/Instances.hs view
@@ -39,6 +39,9 @@ #endif import Data.Vector (Vector,(++),drop,length,imap,ifoldr, ifoldl, izipWith,(!?),(//), generate) import qualified Data.Vector as Vector+#if MIN_VERSION_vector(0,13,2)+import qualified Data.Vector.Strict as Vector.Strict+#endif import qualified Data.Vector.Unboxed as Unboxed import qualified Data.Vector.Storable as Storable import qualified Data.Vector.Primitive as Primitive@@ -138,6 +141,16 @@ instance (Hashable a) => Hashable (Vector a) where   hashWithSalt salt = hashWithSalt salt . Vector.toList   {-# INLINE hashWithSalt #-}++#if MIN_VERSION_vector(0,13,2)+instance (Hashable a) => Hashable (Vector.Strict.Vector a) where+  hashWithSalt salt = hashWithSalt salt . Vector.Strict.toList+  {-# INLINE hashWithSalt #-}++instance Hashable1 Vector.Strict.Vector where+  liftHashWithSalt itemHashWithSalt salt = liftHashWithSalt itemHashWithSalt salt . Vector.Strict.toList+  {-# INLINE liftHashWithSalt #-}+#endif  instance (Unboxed.Unbox a, Hashable a) => Hashable (Unboxed.Vector a) where   hashWithSalt salt = hashWithSalt salt . Unboxed.toList
vector-instances.cabal view
@@ -1,5 +1,5 @@ name:                vector-instances-version:             3.4.2+version:             3.4.3 synopsis:            Orphan Instances for 'Data.Vector' description:         Orphan Instances for 'Data.Vector'. homepage:            http://github.com/ekmett/vector-instances@@ -20,8 +20,11 @@   GHC==8.10.7,   GHC==9.0.2,   GHC==9.2.7,-  GHC==9.4.4,-  GHC==9.6.1+  GHC==9.4.8,+  GHC==9.6.7,+  GHC==9.8.4,+  GHC==9.10.2,+  GHC==9.12.2 extra-source-files:   .vim.custom   .gitignore@@ -30,7 +33,7 @@  source-repository head   type: git-  location: git://github.com/ekmett/vector-instances.git+  location: https://github.com/ekmett/vector-instances.git  flag hashable   description: