Commit 96f21260 authored by Ian Lynagh's avatar Ian Lynagh

Remove the ID Monad

We don't use it, and if we want an identity Monad then there's one
in transformers:Data.Functor.Identity that we could use.
parent 5efe3986
......@@ -16,8 +16,6 @@ module MonadUtils
, MonadFix(..)
, MonadIO(..)
, ID, runID
, liftIO1, liftIO2, liftIO3, liftIO4
, zipWith3M
......@@ -32,8 +30,6 @@ module MonadUtils
, maybeMapM
) where
import Outputable
-------------------------------------------------------------------------------
-- Detection of available libraries
-------------------------------------------------------------------------------
......@@ -54,20 +50,6 @@ import Control.Monad.Trans
import Control.Monad
import Control.Monad.Fix
-------------------------------------------------------------------------------
-- The ID monad
-------------------------------------------------------------------------------
newtype ID a = ID a
instance Monad ID where
return x = ID x
(ID x) >>= f = f x
_ >> y = y
fail s = panic s
runID :: ID a -> a
runID (ID x) = x
-------------------------------------------------------------------------------
-- MTL
-------------------------------------------------------------------------------
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment