Skip to content

Commit ecfda27

Browse files
committed
Deprecate dot
1 parent 88ccea0 commit ecfda27

File tree

1 file changed

+2
-9
lines changed

1 file changed

+2
-9
lines changed

Control/Parallel/Strategies.hs

Lines changed: 2 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -358,7 +358,7 @@ x `usingIO` strat = runEvalIO (strat x)
358358
withStrategyIO :: Strategy a -> a -> IO a
359359
withStrategyIO = flip usingIO
360360

361-
-- | Compose two strategies sequentially.
361+
-- | Compose two strategies.
362362
--
363363
-- > strat2 `dot` strat1 == strat2 . withStrategy strat1
364364
--
@@ -370,14 +370,7 @@ withStrategyIO = flip usingIO
370370
--
371371
-- > strat `dot` r0 == strat
372372
-- > strat `dot` rseq == strat
373-
--
374-
-- Furthermore, since strategies should only force and spark computations
375-
-- (that is, they don't actually change any values),
376-
--
377-
-- > strat `dot` strat == strat
378-
--
379-
-- Perhaps unexpectedly, @r0 `dot` strat == r0@.
380-
-- 'Control.Monad.<=<' has a more intuitive behaviour (@r0 <=< strat == strat@).
373+
{-# DEPRECATED dot "'dot' is an unintuitive composition operator. Use 'Control.Monad.<=<` instead." #-}
381374
dot :: Strategy a -> Strategy a -> Strategy a
382375
strat2 `dot` strat1 = strat2 . runEval . strat1
383376

0 commit comments

Comments
 (0)