summaryrefslogtreecommitdiff
path: root/src/runtime/haskell
diff options
context:
space:
mode:
authorInari Listenmaa <inari.listenmaa@gmail.com>2021-06-29 23:48:00 +0200
committerGitHub <noreply@github.com>2021-06-29 23:48:00 +0200
commit6efbd23c5cf450f3702e628225872650a619270f (patch)
treefbe74bc715730c2932da4e6d7492942beaecd1c0 /src/runtime/haskell
parent3a27fa0d390b86cab3ecc68418e4116ea5c4f8ba (diff)
parent76bec6d71e7c4fdffa2e618ec6578e0858166465 (diff)
Merge pull request #84 from ffrixslee/issue-46
Issue 46 (various deprecations during compilation of GF)
Diffstat (limited to 'src/runtime/haskell')
-rw-r--r--src/runtime/haskell/Data/Binary/Builder.hs4
-rw-r--r--src/runtime/haskell/Data/Binary/Get.hs2
-rw-r--r--src/runtime/haskell/PGF/TypeCheck.hs2
3 files changed, 4 insertions, 4 deletions
diff --git a/src/runtime/haskell/Data/Binary/Builder.hs b/src/runtime/haskell/Data/Binary/Builder.hs
index b69371f0e..a74428f20 100644
--- a/src/runtime/haskell/Data/Binary/Builder.hs
+++ b/src/runtime/haskell/Data/Binary/Builder.hs
@@ -68,7 +68,7 @@ import qualified Data.ByteString.Lazy as L
import Data.ByteString.Base (inlinePerformIO)
import qualified Data.ByteString.Base as S
#else
-import Data.ByteString.Internal (inlinePerformIO)
+import Data.ByteString.Internal (accursedUnutterablePerformIO)
import qualified Data.ByteString.Internal as S
--import qualified Data.ByteString.Lazy.Internal as L
#endif
@@ -199,7 +199,7 @@ defaultSize = 32 * k - overhead
-- | Sequence an IO operation on the buffer
unsafeLiftIO :: (Buffer -> IO Buffer) -> Builder
-unsafeLiftIO f = Builder $ \ k buf -> inlinePerformIO $ do
+unsafeLiftIO f = Builder $ \ k buf -> accursedUnutterablePerformIO $ do
buf' <- f buf
return (k buf')
{-# INLINE unsafeLiftIO #-}
diff --git a/src/runtime/haskell/Data/Binary/Get.hs b/src/runtime/haskell/Data/Binary/Get.hs
index 01561d7d9..54f17ae95 100644
--- a/src/runtime/haskell/Data/Binary/Get.hs
+++ b/src/runtime/haskell/Data/Binary/Get.hs
@@ -423,7 +423,7 @@ readN n f = fmap f $ getBytes n
getPtr :: Storable a => Int -> Get a
getPtr n = do
(fp,o,_) <- readN n B.toForeignPtr
- return . B.inlinePerformIO $ withForeignPtr fp $ \p -> peek (castPtr $ p `plusPtr` o)
+ return . B.accursedUnutterablePerformIO $ withForeignPtr fp $ \p -> peek (castPtr $ p `plusPtr` o)
{- INLINE getPtr -}
------------------------------------------------------------------------
diff --git a/src/runtime/haskell/PGF/TypeCheck.hs b/src/runtime/haskell/PGF/TypeCheck.hs
index 5db4ef439..c5cc44b4e 100644
--- a/src/runtime/haskell/PGF/TypeCheck.hs
+++ b/src/runtime/haskell/PGF/TypeCheck.hs
@@ -41,7 +41,7 @@ import Control.Applicative
import Control.Monad
--import Control.Monad.Identity
import Control.Monad.State
-import Control.Monad.Error
+import Control.Monad.Except
import Text.PrettyPrint
-----------------------------------------------------