When trying to build GHC 9.14.2-rc1 with GHC 9.12.4 as the boot compiler
the build failed due to a missing "Binary" instance for "HalfWord".
I see that Ben Gamari already had to implement a work-around for this:
commit b965fa766c6bdf1bf3c8be63a6187e1100051599
Author: Ben Gamari <[email protected]>
Date: Sat Oct 4 11:45:32 2025 -0400
ghci: Fix CPP guarding Binary HalfWord instance
diff --git a/libraries/ghci/GHCi/Message.hs b/libraries/ghci/GHCi/Message.hs
index 072f46cd32..c731d33e31 100644
--- a/libraries/ghci/GHCi/Message.hs
+++ b/libraries/ghci/GHCi/Message.hs
@@ -522,7 +522,7 @@ instance Binary (FunPtr a) where
put = put . castFunPtrToPtr
get = castPtrToFunPtr <$> get
-#if MIN_VERSION_ghc_internal(9,1500,0)
+#if MIN_VERSION_ghc_internal(9,1400,0)
instance Binary Heap.HalfWord where
put x = put (fromIntegral x :: Word32)
get = fromIntegral <$> (get :: Get Word32)
I had to further reduce this from 1400 to 1204.
--
Viktor. 🇺🇦 Слава Україні!
_______________________________________________
ghc-devs mailing list -- [email protected]
To unsubscribe send an email to [email protected]