[commit: packages/binary] master: Conditionally include Data.Monoid for older GHC versions. (f9ff5c3)

git at git.haskell.org git at git.haskell.org
Wed Dec 16 09:43:07 UTC 2015


Repository : ssh://git@git.haskell.org/binary

On branch  : master
Link       : http://git.haskell.org/packages/binary.git/commitdiff/f9ff5c36f46f4f6d12baf5ab2fce7d553dba712f

>---------------------------------------------------------------

commit f9ff5c36f46f4f6d12baf5ab2fce7d553dba712f
Author: Lennart Kolmodin <kolmodin at google.com>
Date:   Fri Aug 14 22:30:16 2015 +0200

    Conditionally include Data.Monoid for older GHC versions.


>---------------------------------------------------------------

f9ff5c36f46f4f6d12baf5ab2fce7d553dba712f
 benchmarks/Builder.hs | 5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)

diff --git a/benchmarks/Builder.hs b/benchmarks/Builder.hs
index 042b371..71a202f 100644
--- a/benchmarks/Builder.hs
+++ b/benchmarks/Builder.hs
@@ -6,6 +6,10 @@
 
 module Main (main) where
 
+#if ! MIN_VERSION_base(4,8,0)
+import Data.Monoid (Monoid(mappend, mempty))
+#endif
+
 import Control.DeepSeq
 import Control.Exception (evaluate)
 import Control.Monad.Trans (liftIO)
@@ -14,7 +18,6 @@ import qualified Data.ByteString as S
 import qualified Data.ByteString.Char8 as C
 import qualified Data.ByteString.Lazy as L
 import Data.Char (ord)
-import Data.Monoid (Monoid(mappend, mempty))
 import Data.Word (Word8)
 
 import Data.Binary.Builder



More information about the ghc-commits mailing list