summaryrefslogtreecommitdiff
path: root/dev-haskell/hex/files/hex-0.1.2-monadfail.patch
blob: 27caaf0774f21ea994ea040b995c559049bcfee0 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
--- hex-0.1.2/Data/Hex.hs	2011-10-11 05:44:11.000000000 +1100
+++ Data/Hex.hs	2020-08-01 12:28:49.166983032 +1000
@@ -22,7 +22,7 @@
     -- | Convert string into hexadecimal.
     hex   :: t -> t
     -- | Convert from hexadecimal and fail on invalid input.
-    unhex :: Monad m => t -> m t
+    unhex :: (Monad m, MonadFail m) => t -> m t
 
 
 instance Hex String where
@@ -37,7 +37,7 @@
     unhex [_]      = fail "Non-even length"
 
 
-c :: Monad m => Char -> m Int
+c :: (Monad m, MonadFail m) => Char -> m Int
 c '0' = return 0
 c '1' = return 1
 c '2' = return 2