Skip to content

Commit ae7e847

Browse files
committed
Use GHC.Types.SPEC instead of GHC.Exts.SpecConstrAnnotation
This means GHCi isn't needed anymore to build vector. This has a couple of advantages: * `vector` can now be built with a stage1 compiler (e.g. iOS cross-compiler) [1] * `vector` and its dependencies can now be build on a noexec mounted disk, preventing bug reports such as [2] GHC.Types.SPEC was added to ghc-prim 0.3.1.0 / GHC 7.8.1 [3]. [1] http://git.haskell.org/ghc.git/commitdiff/cee3adbcc180bdf1be8b24aeaafa2ca4a737cbbf [2] https://ghc.haskell.org/trac/ghc/ticket/10131 [3] https://downloads.haskell.org/~ghc/7.8.1/docs/html/users_guide/release-7-8-1.html
1 parent 764aa2e commit ae7e847

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

Data/Vector/Fusion/Stream/Monadic.hs

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -92,17 +92,21 @@ import Prelude hiding ( length, null,
9292
import Data.Int ( Int8, Int16, Int32, Int64 )
9393
import Data.Word ( Word8, Word16, Word32, Word, Word64 )
9494

95-
#if __GLASGOW_HASKELL__ >= 700
95+
#if __GLASGOW_HASKELL__ >= 708
96+
import GHC.Types ( SPEC(..) )
97+
#elif __GLASGOW_HASKELL__ >= 700
9698
import GHC.Exts ( SpecConstrAnnotation(..) )
9799
#endif
98100

99101
#include "vector.h"
100102
#include "MachDeps.h"
101103

104+
#if __GLASGOW_HASKELL__ < 708
102105
data SPEC = SPEC | SPEC2
103106
#if __GLASGOW_HASKELL__ >= 700
104107
{-# ANN type SPEC ForceSpecConstr #-}
105108
#endif
109+
#endif
106110

107111
emptyStream :: String
108112
{-# NOINLINE emptyStream #-}

0 commit comments

Comments
 (0)