From ff03f4f8b4ac1b9ccd9ef93c294ac835871c349f Mon Sep 17 00:00:00 2001 From: David Waern Date: Fri, 10 Oct 2008 20:33:38 +0000 Subject: Make Haddock build with GHC 6.8.2 --- src/Haddock/Utils.hs | 11 +++++++++++ 1 file changed, 11 insertions(+) (limited to 'src/Haddock/Utils.hs') diff --git a/src/Haddock/Utils.hs b/src/Haddock/Utils.hs index 5743cbe1..8fe64b30 100644 --- a/src/Haddock/Utils.hs +++ b/src/Haddock/Utils.hs @@ -36,6 +36,9 @@ module Haddock.Utils ( -- * Binary extras -- FormatVersion, mkFormatVersion + + -- * MTL stuff + MonadIO(..) ) where import Haddock.Types @@ -64,6 +67,14 @@ import System.Exit ( exitWith, ExitCode(..) ) import System.IO ( hPutStr, stderr ) import System.IO.Unsafe ( unsafePerformIO ) +#if __GLASGOW_HASKELL__ >= 609 +import MonadUtils ( MonadIO(..) ) +#else +class Monad m => MonadIO m where + liftIO :: IO a -> m a +instance MonadIO IO where liftIO = id +#endif + -- ----------------------------------------------------------------------------- -- Some Utilities -- cgit v1.2.3