Add support for Int16#, Word16#
authorBen Gamari <ben@smart-cactus.org>
Mon, 5 Nov 2018 17:44:06 +0000 (12:44 -0500)
committerBen Gamari <ben@smart-cactus.org>
Mon, 5 Nov 2018 17:44:06 +0000 (12:44 -0500)
src/Data/Binary/Class.hs

index b44001d..690f3da 100644 (file)
@@ -885,6 +885,8 @@ instance Binary RuntimeRep where
 #if __GLASGOW_HASKELL__ >= 807
     put Int8Rep         = putWord8 12
     put Word8Rep        = putWord8 13
+    put Int16Rep        = putWord8 14
+    put Word16Rep       = putWord8 15
 #endif
 
     get = do
@@ -905,6 +907,8 @@ instance Binary RuntimeRep where
 #if __GLASGOW_HASKELL__ >= 807
           12 -> pure Int8Rep
           13 -> pure Word8Rep
+          14 -> pure Int16Rep
+          15 -> pure Word16Rep
 #endif
           _  -> fail "GHCi.TH.Binary.putRuntimeRep: invalid tag"