Skip to content

Commit f59bb26

Browse files
authored
Drop support for hashable < 1.2.5 (#355)
Stackage snapshots for GHC 8.2 use hashable-1.2.7.0, so this shouldn't cause any problems.
1 parent 5c57564 commit f59bb26

File tree

3 files changed

+4
-12
lines changed

3 files changed

+4
-12
lines changed

Data/HashMap/Internal.hs

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -163,9 +163,7 @@ import qualified GHC.Exts as Exts
163163
import Data.Functor.Classes
164164
import GHC.Stack
165165

166-
#if MIN_VERSION_hashable(1,2,5)
167166
import qualified Data.Hashable.Lifted as H
168-
#endif
169167

170168
import qualified Control.DeepSeq as NF
171169

@@ -486,7 +484,6 @@ equalKeys = go
486484

487485
leafEq (L k1 _) (L k2 _) = k1 == k2
488486

489-
#if MIN_VERSION_hashable(1,2,5)
490487
instance H.Hashable2 HashMap where
491488
liftHashWithSalt2 hk hv salt hm = go salt (toList' hm [])
492489
where
@@ -512,7 +509,6 @@ instance H.Hashable2 HashMap where
512509

513510
instance (Hashable k) => H.Hashable1 (HashMap k) where
514511
liftHashWithSalt = H.liftHashWithSalt2 H.hashWithSalt
515-
#endif
516512

517513
instance (Hashable k, Hashable v) => Hashable (HashMap k v) where
518514
hashWithSalt salt hm = go salt hm

Data/HashSet/Internal.hs

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -106,9 +106,7 @@ import qualified Data.HashMap.Internal as H
106106
import qualified Data.List as List
107107
import Text.Read
108108

109-
#if MIN_VERSION_hashable(1,2,5)
110109
import qualified Data.Hashable.Lifted as H
111-
#endif
112110

113111
import qualified Control.DeepSeq as NF
114112
import qualified Language.Haskell.TH.Syntax as TH
@@ -241,10 +239,8 @@ instance (Data a, Eq a, Hashable a) => Data (HashSet a) where
241239
dataTypeOf _ = hashSetDataType
242240
dataCast1 f = gcast1 f
243241

244-
#if MIN_VERSION_hashable(1,2,6)
245242
instance H.Hashable1 HashSet where
246243
liftHashWithSalt h s = H.liftHashWithSalt2 h hashWithSalt s . asMap
247-
#endif
248244

249245
instance (Hashable a) => Hashable (HashSet a) where
250246
hashWithSalt salt = hashWithSalt salt . asMap

unordered-containers.cabal

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -55,7 +55,7 @@ library
5555
build-depends:
5656
base >= 4.10 && < 5,
5757
deepseq >= 1.4.3,
58-
hashable >= 1.0.1.1 && < 1.5,
58+
hashable >= 1.2.5 && < 1.5,
5959
template-haskell < 2.19
6060

6161
default-language: Haskell2010
@@ -89,7 +89,7 @@ test-suite unordered-containers-tests
8989
base,
9090
ChasingBottoms,
9191
containers >= 0.5.8,
92-
hashable >= 1.0.1.1,
92+
hashable,
9393
HUnit,
9494
QuickCheck >= 2.4.0.1,
9595
random,
@@ -116,8 +116,8 @@ benchmark benchmarks
116116
base >= 4.8.0,
117117
bytestring >= 0.10.0.0,
118118
containers,
119-
deepseq >= 1.4,
120-
hashable >= 1.0.1.1,
119+
deepseq,
120+
hashable,
121121
hashmap,
122122
mtl,
123123
random,

0 commit comments

Comments
 (0)