[commit: packages/binary] master: Add support for Int8Rep/Word8Rep added in GHC 8.7 (64b5414)
git at git.haskell.org
git at git.haskell.org
Sun Oct 7 22:35:00 UTC 2018
Repository : ssh://git@git.haskell.org/binary
On branch : master
Link : http://git.haskell.org/packages/binary.git/commitdiff/64b5414bfb7cab667124a71f251668e114ba1500
>---------------------------------------------------------------
commit 64b5414bfb7cab667124a71f251668e114ba1500
Author: Ben Gamari <ben at smart-cactus.org>
Date: Thu Oct 4 16:28:41 2018 -0400
Add support for Int8Rep/Word8Rep added in GHC 8.7
>---------------------------------------------------------------
64b5414bfb7cab667124a71f251668e114ba1500
src/Data/Binary/Class.hs | 8 ++++++++
1 file changed, 8 insertions(+)
diff --git a/src/Data/Binary/Class.hs b/src/Data/Binary/Class.hs
index 2eed93e..b44001d 100644
--- a/src/Data/Binary/Class.hs
+++ b/src/Data/Binary/Class.hs
@@ -882,6 +882,10 @@ instance Binary RuntimeRep where
put AddrRep = putWord8 9
put FloatRep = putWord8 10
put DoubleRep = putWord8 11
+#if __GLASGOW_HASKELL__ >= 807
+ put Int8Rep = putWord8 12
+ put Word8Rep = putWord8 13
+#endif
get = do
tag <- getWord8
@@ -898,6 +902,10 @@ instance Binary RuntimeRep where
9 -> pure AddrRep
10 -> pure FloatRep
11 -> pure DoubleRep
+#if __GLASGOW_HASKELL__ >= 807
+ 12 -> pure Int8Rep
+ 13 -> pure Word8Rep
+#endif
_ -> fail "GHCi.TH.Binary.putRuntimeRep: invalid tag"
-- | @since 0.8.5.0. See #typeable-instances#
More information about the ghc-commits
mailing list