summaryrefslogtreecommitdiff
path: root/compiler/simplCore/CoreMonad.hs
diff options
context:
space:
mode:
Diffstat (limited to 'compiler/simplCore/CoreMonad.hs')
-rw-r--r--compiler/simplCore/CoreMonad.hs5
1 files changed, 2 insertions, 3 deletions
diff --git a/compiler/simplCore/CoreMonad.hs b/compiler/simplCore/CoreMonad.hs
index 3a2277a7a7..29e4b00c4d 100644
--- a/compiler/simplCore/CoreMonad.hs
+++ b/compiler/simplCore/CoreMonad.hs
@@ -5,6 +5,7 @@
-}
{-# LANGUAGE CPP #-}
+{-# LANGUAGE DeriveFunctor #-}
module CoreMonad (
-- * Configuration of the core-to-core passes
@@ -582,9 +583,7 @@ type CoreIOEnv = IOEnv CoreReader
-- | The monad used by Core-to-Core passes to access common state, register simplification
-- statistics and so on
newtype CoreM a = CoreM { unCoreM :: CoreState -> CoreIOEnv (a, CoreState, CoreWriter) }
-
-instance Functor CoreM where
- fmap = liftM
+ deriving (Functor)
instance Monad CoreM where
mx >>= f = CoreM $ \s -> do