Squashed commit of the following:
commit a6f62265f345c8b7a7226515171752586b0d66e5 Author: Stephen Diehl <stephen.m.diehl@gmail.com> Date: Wed Apr 13 13:41:05 2016 -0400 bump version commit 1a809623cd1484ce215612e6b3ecef15015bc602 Author: Stephen Diehl <stephen.m.diehl@gmail.com> Date: Wed Apr 13 13:26:11 2016 -0400 masking for ghc 8.0 specific type commit 54bafb0bb80c8450863eac53a1f3a20a21c8b0c9 Author: Stephen Diehl <stephen.m.diehl@gmail.com> Date: Wed Apr 13 12:55:08 2016 -0400 bump ghc-prim for GHC 8.0 compat commit 8808d5f37369107b3e5961255089a8a9e02bf3d5 Author: Stephen Diehl <stephen.m.diehl@gmail.com> Date: Wed Apr 13 12:53:39 2016 -0400 expose base State transformers commit 05c32a4542aa66f715aea3855e140f74e97d4852 Author: Stephen Diehl <stephen.m.diehl@gmail.com> Date: Wed Apr 13 12:46:00 2016 -0400 adds compiler-independent base module
This commit is contained in:
+57
@@ -0,0 +1,57 @@
|
||||
{-# LANGUAGE CPP #-}
|
||||
{-# LANGUAGE Unsafe #-}
|
||||
{-# LANGUAGE BangPatterns #-}
|
||||
{-# LANGUAGE NoImplicitPrelude #-}
|
||||
|
||||
module Base (
|
||||
module X,
|
||||
($!),
|
||||
) where
|
||||
|
||||
-- Glorious Glashgow Haskell Compiler
|
||||
#if defined(__GLASGOW_HASKELL__) && ( __GLASGOW_HASKELL__ >= 600 )
|
||||
|
||||
-- Base GHC types
|
||||
import GHC.Num as X
|
||||
import GHC.Enum as X
|
||||
import GHC.Real as X
|
||||
import GHC.Float as X
|
||||
import GHC.Show as X
|
||||
import GHC.Exts as X (
|
||||
Constraint
|
||||
, Ptr
|
||||
, FunPtr
|
||||
, the
|
||||
)
|
||||
import GHC.Base as X (
|
||||
(++)
|
||||
, seq
|
||||
, asTypeOf
|
||||
)
|
||||
import System.IO as X (
|
||||
print
|
||||
, putStr
|
||||
, putStrLn
|
||||
)
|
||||
|
||||
#if ( __GLASGOW_HASKELL__ >= 800 )
|
||||
import GHC.Types as X hiding (Any)
|
||||
#else
|
||||
import GHC.Types as X
|
||||
#endif
|
||||
|
||||
infixr 0 $!
|
||||
|
||||
($!) :: (a -> b) -> a -> b
|
||||
f $! x = let !vx = x in f vx
|
||||
|
||||
#endif
|
||||
|
||||
-- Simple Haskell Compiler
|
||||
#if defined(__SHC_HASKELL__)
|
||||
|
||||
import SHC.Prim as X
|
||||
import SHC.Types as X
|
||||
import SHC.Classes as X
|
||||
|
||||
#endif
|
||||
Reference in New Issue
Block a user