@@ -20,10 +20,10 @@ toListSerial :: SerialT IO a -> IO [a]
20toListSerial = A.toList . serially
20toListSerial = A.toList . serially
22toListInterleaved :: InterleavedT IO a -> IO [a]
22toListInterleaved :: InterleavedT IO a -> IO [a]
23−toListInterleaved = A.toList . interleaving
23+toListInterleaved = A.toList . coserially
25toListAsync :: AParallelT IO a -> IO [a]
25toListAsync :: AParallelT IO a -> IO [a]
26−toListAsync = A.toList . aparallely
26+toListAsync = A.toList . coparallely
28toListParallel :: ParallelT IO a -> IO [a]
28toListParallel :: ParallelT IO a -> IO [a]
29toListParallel = A.toList . parallely
29toListParallel = A.toList . parallely
@@ -88,8 +88,8 @@ main = hspec $ do
88 ---------------------------------------------------------------------------
88 ---------------------------------------------------------------------------
90 describe "Serial Composition" $ compose serially mempty id
90 describe "Serial Composition" $ compose serially mempty id
91− describe "Interleaved Composition" $ compose interleaving mempty sort
91+ describe "Interleaved Composition" $ compose coserially mempty sort
92− describe "Left biased parallel Composition" $ compose aparallely mempty sort
92+ describe "Left biased parallel Composition" $ compose coparallely mempty sort
93 describe "Fair parallel Composition" $ compose parallely mempty sort
93 describe "Fair parallel Composition" $ compose parallely mempty sort
94 describe "Semigroup Composition for ZipSerial" $ compose zipping mempty id
94 describe "Semigroup Composition for ZipSerial" $ compose zipping mempty id
95 describe "Semigroup Composition for ZipAsync" $ compose zippingAsync mempty id
95 describe "Semigroup Composition for ZipAsync" $ compose zippingAsync mempty id
@@ -98,9 +98,9 @@ main = hspec $ do
98 -- Monoidal Composition ordering checks
98 -- Monoidal Composition ordering checks
99 ---------------------------------------------------------------------------
99 ---------------------------------------------------------------------------
101− describe "Serial interleaved ordering check" $ interleaveCheck interleaving
101+ describe "Serial interleaved ordering check" $ interleaveCheck coserially
102 describe "Parallel interleaved ordering check" $ interleaveCheck parallely
102 describe "Parallel interleaved ordering check" $ interleaveCheck parallely
103− describe "Left biased parallel time order check" $ parallelCheck aparallely
103+ describe "Left biased parallel time order check" $ parallelCheck coparallely
104 describe "Fair parallel time order check" $ parallelCheck parallely
104 describe "Fair parallel time order check" $ parallelCheck parallely
106 ---------------------------------------------------------------------------
106 ---------------------------------------------------------------------------
@@ -112,7 +112,7 @@ main = hspec $ do
113 describe "<> and <=>" $ composeAndComposeSimple
113 describe "<> and <=>" $ composeAndComposeSimple
115− interleaving
115+ coserially
116 ([ [1 .. 9]
116 ([ [1 .. 9]
117 , [1 .. 9]
117 , [1 .. 9]
118 , [1, 3, 2, 4, 6, 5, 7, 9, 8]
118 , [1, 3, 2, 4, 6, 5, 7, 9, 8]
@@ -120,8 +120,8 @@ main = hspec $ do
122 describe "<=> and <=>" $ composeAndComposeSimple
122 describe "<=> and <=>" $ composeAndComposeSimple
123− interleaving
123+ coserially
124− interleaving
124+ coserially
125 ([ [1, 4, 2, 7, 3, 5, 8, 6, 9]
125 ([ [1, 4, 2, 7, 3, 5, 8, 6, 9]
126 , [1, 7, 4, 8, 2, 9, 5, 3, 6]
126 , [1, 7, 4, 8, 2, 9, 5, 3, 6]
127 , [1, 4, 3, 7, 2, 6, 9, 5, 8]
127 , [1, 4, 3, 7, 2, 6, 9, 5, 8]
@@ -129,7 +129,7 @@ main = hspec $ do
131 describe "<=> and <>" $ composeAndComposeSimple
131 describe "<=> and <>" $ composeAndComposeSimple
132− interleaving
132+ coserially
134 ([ [1, 4, 2, 7, 3, 5, 8, 6, 9]
134 ([ [1, 4, 2, 7, 3, 5, 8, 6, 9]
135 , [1, 7, 4, 8, 2, 9, 5, 3, 6]
135 , [1, 7, 4, 8, 2, 9, 5, 3, 6]
@@ -183,7 +183,7 @@ main = hspec $ do
183 ---------------------------------------------------------------------------
183 ---------------------------------------------------------------------------
185 describe "Serial loops (<>)" $ loops serially id reverse
185 describe "Serial loops (<>)" $ loops serially id reverse
186− describe "Left biased parallel loops (<|)" $ loops aparallely sort sort
186+ describe "Left biased parallel loops (<|)" $ loops coparallely sort sort
187 describe "Fair parallel loops (<|>)" $ loops parallely sort sort
187 describe "Fair parallel loops (<|>)" $ loops parallely sort sort
189 ---------------------------------------------------------------------------
189 ---------------------------------------------------------------------------
@@ -191,23 +191,23 @@ main = hspec $ do
191 ---------------------------------------------------------------------------
191 ---------------------------------------------------------------------------
193 describe "Bind and compose1" $ bindAndComposeSimple serially serially
193 describe "Bind and compose1" $ bindAndComposeSimple serially serially
194− describe "Bind and compose2" $ bindAndComposeSimple serially interleaving
194+ describe "Bind and compose2" $ bindAndComposeSimple serially coserially
195− describe "Bind and compose3" $ bindAndComposeSimple serially aparallely
195+ describe "Bind and compose3" $ bindAndComposeSimple serially coparallely
196 describe "Bind and compose4" $ bindAndComposeSimple serially parallely
196 describe "Bind and compose4" $ bindAndComposeSimple serially parallely
198− describe "Bind and compose1" $ bindAndComposeSimple interleaving serially
198+ describe "Bind and compose1" $ bindAndComposeSimple coserially serially
199− describe "Bind and compose2" $ bindAndComposeSimple interleaving interleaving
199+ describe "Bind and compose2" $ bindAndComposeSimple coserially coserially
200− describe "Bind and compose3" $ bindAndComposeSimple interleaving aparallely
200+ describe "Bind and compose3" $ bindAndComposeSimple coserially coparallely
201− describe "Bind and compose4" $ bindAndComposeSimple interleaving parallely
201+ describe "Bind and compose4" $ bindAndComposeSimple coserially parallely
203− describe "Bind and compose1" $ bindAndComposeSimple aparallely serially
203+ describe "Bind and compose1" $ bindAndComposeSimple coparallely serially
204− describe "Bind and compose2" $ bindAndComposeSimple aparallely interleaving
204+ describe "Bind and compose2" $ bindAndComposeSimple coparallely coserially
205− describe "Bind and compose3" $ bindAndComposeSimple aparallely aparallely
205+ describe "Bind and compose3" $ bindAndComposeSimple coparallely coparallely
206− describe "Bind and compose4" $ bindAndComposeSimple aparallely parallely
206+ describe "Bind and compose4" $ bindAndComposeSimple coparallely parallely
208 describe "Bind and compose1" $ bindAndComposeSimple parallely serially
208 describe "Bind and compose1" $ bindAndComposeSimple parallely serially
209− describe "Bind and compose2" $ bindAndComposeSimple parallely interleaving
209+ describe "Bind and compose2" $ bindAndComposeSimple parallely coserially
210− describe "Bind and compose3" $ bindAndComposeSimple parallely aparallely
210+ describe "Bind and compose3" $ bindAndComposeSimple parallely coparallely
211 describe "Bind and compose4" $ bindAndComposeSimple parallely parallely
211 describe "Bind and compose4" $ bindAndComposeSimple parallely parallely
213 let fldr, fldl :: (IsStream t, Semigroup (t IO Int)) => [t IO Int] -> t IO Int
213 let fldr, fldl :: (IsStream t, Semigroup (t IO Int)) => [t IO Int] -> t IO Int
@@ -217,36 +217,36 @@ main = hspec $ do
217 forM_ [fldr, fldl] $ \k ->
217 forM_ [fldr, fldl] $ \k ->
218 describe "Bind and compose" $ bindAndComposeHierarchy serially serially k
218 describe "Bind and compose" $ bindAndComposeHierarchy serially serially k
219 forM_ [fldr, fldl] $ \k ->
219 forM_ [fldr, fldl] $ \k ->
220− describe "Bind and compose" $ bindAndComposeHierarchy serially interleaving k
220+ describe "Bind and compose" $ bindAndComposeHierarchy serially coserially k
221 forM_ [fldr, fldl] $ \k ->
221 forM_ [fldr, fldl] $ \k ->
222− describe "Bind and compose" $ bindAndComposeHierarchy serially aparallely k
222+ describe "Bind and compose" $ bindAndComposeHierarchy serially coparallely k
223 forM_ [fldr, fldl] $ \k ->
223 forM_ [fldr, fldl] $ \k ->
224 describe "Bind and compose" $ bindAndComposeHierarchy serially parallely k
224 describe "Bind and compose" $ bindAndComposeHierarchy serially parallely k
226 forM_ [fldr, fldl] $ \k ->
226 forM_ [fldr, fldl] $ \k ->
227− describe "Bind and compose" $ bindAndComposeHierarchy interleaving serially k
227+ describe "Bind and compose" $ bindAndComposeHierarchy coserially serially k
228 forM_ [fldr, fldl] $ \k ->
228 forM_ [fldr, fldl] $ \k ->
229− describe "Bind and compose" $ bindAndComposeHierarchy interleaving interleaving k
229+ describe "Bind and compose" $ bindAndComposeHierarchy coserially coserially k
230 forM_ [fldr, fldl] $ \k ->
230 forM_ [fldr, fldl] $ \k ->
231− describe "Bind and compose" $ bindAndComposeHierarchy interleaving aparallely k
231+ describe "Bind and compose" $ bindAndComposeHierarchy coserially coparallely k
232 forM_ [fldr, fldl] $ \k ->
232 forM_ [fldr, fldl] $ \k ->
233− describe "Bind and compose" $ bindAndComposeHierarchy interleaving parallely k
233+ describe "Bind and compose" $ bindAndComposeHierarchy coserially parallely k
235 forM_ [fldr, fldl] $ \k ->
235 forM_ [fldr, fldl] $ \k ->
236− describe "Bind and compose" $ bindAndComposeHierarchy aparallely serially k
236+ describe "Bind and compose" $ bindAndComposeHierarchy coparallely serially k
237 forM_ [fldr, fldl] $ \k ->
237 forM_ [fldr, fldl] $ \k ->
238− describe "Bind and compose" $ bindAndComposeHierarchy aparallely interleaving k
238+ describe "Bind and compose" $ bindAndComposeHierarchy coparallely coserially k
239 forM_ [fldr, fldl] $ \k ->
239 forM_ [fldr, fldl] $ \k ->
240− describe "Bind and compose" $ bindAndComposeHierarchy aparallely aparallely k
240+ describe "Bind and compose" $ bindAndComposeHierarchy coparallely coparallely k
241 forM_ [fldr, fldl] $ \k ->
241 forM_ [fldr, fldl] $ \k ->
242− describe "Bind and compose" $ bindAndComposeHierarchy aparallely parallely k
242+ describe "Bind and compose" $ bindAndComposeHierarchy coparallely parallely k
244 forM_ [fldr, fldl] $ \k ->
244 forM_ [fldr, fldl] $ \k ->
245 describe "Bind and compose" $ bindAndComposeHierarchy parallely serially k
245 describe "Bind and compose" $ bindAndComposeHierarchy parallely serially k
246 forM_ [fldr, fldl] $ \k ->
246 forM_ [fldr, fldl] $ \k ->
247− describe "Bind and compose" $ bindAndComposeHierarchy parallely interleaving k
247+ describe "Bind and compose" $ bindAndComposeHierarchy parallely coserially k
248 forM_ [fldr, fldl] $ \k ->
248 forM_ [fldr, fldl] $ \k ->
249− describe "Bind and compose" $ bindAndComposeHierarchy parallely aparallely k
249+ describe "Bind and compose" $ bindAndComposeHierarchy parallely coparallely k
250 forM_ [fldr, fldl] $ \k ->
250 forM_ [fldr, fldl] $ \k ->
251 describe "Bind and compose" $ bindAndComposeHierarchy parallely parallely k
251 describe "Bind and compose" $ bindAndComposeHierarchy parallely parallely k
@@ -553,11 +553,11 @@ mixedOps = do
553 x1 <- parallely $ return 1 <> return 2
553 x1 <- parallely $ return 1 <> return 2
554 liftIO $ return ()
554 liftIO $ return ()
555 liftIO $ putStr ""
555 liftIO $ putStr ""
556− y1 <- aparallely $ return 1 <> return 2
556+ y1 <- coparallely $ return 1 <> return 2
558 x11 <- return 1 <> return 2
558 x11 <- return 1 <> return 2
559− y11 <- aparallely $ return 1 <> return 2
559+ y11 <- coparallely $ return 1 <> return 2
560− z11 <- interleaving $ return 1 <> return 2
560+ z11 <- coserially $ return 1 <> return 2
561 liftIO $ return ()
561 liftIO $ return ()
562 liftIO $ putStr ""
562 liftIO $ putStr ""
563 return (x11 + y11 + z11)
563 return (x11 + y11 + z11)