[commit: bytestring] master: Fix for ghc-6.8 / base-3 (e4ed1fc)
Ian Lynagh
igloo at earth.li
Wed Feb 22 21:57:51 CET 2012
Repository : ssh://darcs.haskell.org//srv/darcs/packages/bytestring
On branch : master
http://hackage.haskell.org/trac/ghc/changeset/e4ed1fc9e024d587aa4f55f61ffe81e294f27d93
>---------------------------------------------------------------
commit e4ed1fc9e024d587aa4f55f61ffe81e294f27d93
Author: Duncan Coutts <duncan at community.haskell.org>
Date: Mon Nov 7 11:34:00 2011 +0000
Fix for ghc-6.8 / base-3
>---------------------------------------------------------------
Data/ByteString.hs | 7 ++++++-
1 files changed, 6 insertions(+), 1 deletions(-)
diff --git a/Data/ByteString.hs b/Data/ByteString.hs
index bdadf5b..23dceaf 100644
--- a/Data/ByteString.hs
+++ b/Data/ByteString.hs
@@ -2005,7 +2005,12 @@ moduleError fun msg = error (moduleErrorMsg fun msg)
{-# NOINLINE moduleError #-}
moduleErrorIO :: String -> String -> IO a
-moduleErrorIO fun msg = throwIO (userError (moduleErrorMsg fun msg))
+moduleErrorIO fun msg =
+#if MIN_VERSION_base(4,0,0)
+ throwIO . userError $ moduleErrorMsg fun msg
+#else
+ throwIO . IOException . userError $ moduleErrorMsg fun msg
+#endif
{-# NOINLINE moduleErrorIO #-}
moduleErrorMsg :: String -> String -> String
More information about the Cvs-libraries
mailing list