@@ -25,7 +25,7 @@ module Streamly.Streams.Parallel
2525 , parallel
2626 , parallelEndByFirst
2727 , parallelEndByAny
28− , tee
28+ , tapAsync
2929
3030 -- * Function application
3131 , mkParallel
@@ -267,7 +267,7 @@ handleChildException _sv e = do
267267-- @
268268--
269269-- @
270−-- > S.drain $ S.tee (S.mapM_ print) (S.enumerateFromTo 1 2)
270+-- > S.drain $ S.tapAsync (S.mapM_ print) (S.enumerateFromTo 1 2)
271271-- 1
272272-- 2
273273-- @
@@ -282,9 +282,9 @@ handleChildException _sv e = do
282282-- Compare with 'tap'.
283283--
284284-- @since 0.7.0
285−{-# INLINE tee #-}
286−tee :: (IsStream t, MonadAsync m) => (t m a -> m b) -> t m a -> t m a
287−tee f m = mkStream $ \st yld sng stp -> do
285+{-# INLINE tapAsync #-}
286+tapAsync :: (IsStream t, MonadAsync m) => (t m a -> m b) -> t m a -> t m a
287+tapAsync f m = mkStream $ \st yld sng stp -> do
288288 -- Buffer size for the SVar is derived from the current state
289289 sv <- newParallelVar StopNone (adaptState st)
290290 -- XXX exception handling