[project @ 1996-01-08 20:28:12 by partain]
[ghc-hetmet.git] / ghc / lib / prelude / Parallel.lhs
1 %
2 % (c) The GRASP/AQUA Project, Glasgow University, 1995
3 %
4 \section[Parallel]{Parallel Constructs}
5
6 \begin{code}
7 module Parallel (par, seq) 
8
9 where
10
11 infixr 0 `par`
12 infixr 1 `seq`
13
14 par, seq :: a -> b -> b
15
16 #if !defined(__CONCURRENT_HASKELL__) && !defined(__PARALLEL_HASKELL__)
17
18 par a b = b
19 seq a b = b
20
21 #else
22
23 -- Just names without the ugly underscores
24
25 {-# INLINE par #-}
26 par a b = _par_ a b
27
28 {-# INLINE seq #-}
29 seq a b = _seq_ a b
30
31 -- Maybe parIO and the like could be added here later.
32
33 #endif {- __CONCURRENT_HASKELL__ -}
34 \end{code}
35