summaryrefslogtreecommitdiff
path: root/compiler/utils
diff options
context:
space:
mode:
authorSimon Marlow <marlowsd@gmail.com>2008-11-06 10:04:11 +0000
committerSimon Marlow <marlowsd@gmail.com>2008-11-06 10:04:11 +0000
commit2b670a7983da26c0f186d5ebdf195e47a39ee60e (patch)
tree048f658ad8cc76f582b4ea2238a462d9eb604b72 /compiler/utils
parent904addb860eab8d1d46cea0994b67485be1c8890 (diff)
downloadhaskell-2b670a7983da26c0f186d5ebdf195e47a39ee60e.tar.gz
disable MonadPlus instance that doesn't compile with 6.6
Diffstat (limited to 'compiler/utils')
-rw-r--r--compiler/utils/IOEnv.hs6
1 files changed, 6 insertions, 0 deletions
diff --git a/compiler/utils/IOEnv.hs b/compiler/utils/IOEnv.hs
index 305e30eed7..5f354f0e4d 100644
--- a/compiler/utils/IOEnv.hs
+++ b/compiler/utils/IOEnv.hs
@@ -139,9 +139,15 @@ unsafeInterleaveM (IOEnv m) = IOEnv (\ env -> unsafeInterleaveIO (m env))
-- For use if the user has imported Control.Monad.Error from MTL
-- Requires UndecidableInstances
+#if __GLASGOW_HASKELL__ > 606
+-- for some reason, this doesn't compile with GHC 6.6:
+-- utils/IOEnv.hs:144:33:
+-- No instance for (MonadPlus IO)
+-- arising from use of `mplus' at utils/IOEnv.hs:144:33-67
instance MonadPlus IO => MonadPlus (IOEnv env) where
mzero = IOEnv (const mzero)
m `mplus` n = IOEnv (\env -> unIOEnv m env `mplus` unIOEnv n env)
+#endif
----------------------------------------------------------------------
-- Accessing input/output