Hoogle Search

Within LTS Haskell 24.19 (ghc-9.10.3)

Note that Stackage only displays results for the latest LTS and Nightly snapshot. Learn more.

  1. concatMapM :: (IsStream t, Monad m) => (a -> m (t m b)) -> t m a -> t m b

    streamly Streamly.Internal.Data.Stream.IsStream

    Map a stream producing monadic function on each element of the stream and then flatten the results into a single stream. Since the stream generation function is monadic, unlike concatMap, it can produce an effect at the beginning of each iteration of the inner loop.

  2. concatMapM :: (IsStream t, Monad m) => (a -> m (t m b)) -> t m a -> t m b

    streamly Streamly.Internal.Data.Stream.IsStream

    Map a stream producing monadic function on each element of the stream and then flatten the results into a single stream. Since the stream generation function is monadic, unlike concatMap, it can produce an effect at the beginning of each iteration of the inner loop.

  3. concatSmapMWith :: (IsStream t, Monad m) => (t m b -> t m b -> t m b) -> (s -> a -> m (s, t m b)) -> m s -> t m a -> t m b

    streamly Streamly.Internal.Data.Stream.IsStream

    Like concatMapWith but carries a state which can be used to share information across multiple steps of concat.

    concatSmapMWith combine f initial = concatMapWith combine id . smapM f initial
    
    Pre-release

  4. iterateSmapMWith :: (IsStream t, Monad m) => (t m a -> t m a -> t m a) -> (b -> a -> m (b, t m a)) -> m b -> t m a -> t m a

    streamly Streamly.Internal.Data.Stream.IsStream

    Like iterateMap but carries a state in the stream generation function. This can be used to traverse graph like structures, we can remember the visited nodes in the state to avoid cycles. Note that a combination of iterateMap and usingState can also be used to traverse graphs. However, this function provides a more localized state instead of using a global state. See also: mfix Pre-release

  5. rollingMapM :: (IsStream t, Monad m) => (Maybe a -> a -> m b) -> t m a -> t m b

    streamly Streamly.Internal.Data.Stream.IsStream

    Like rollingMap but with an effectful map function. Pre-release

  6. smapM :: (IsStream t, Monad m) => (s -> a -> m (s, b)) -> m s -> t m a -> t m b

    streamly Streamly.Internal.Data.Stream.IsStream

    A stateful mapM, equivalent to a left scan, more like mapAccumL. Hopefully, this is a better alternative to scan. Separation of state from the output makes it easier to think in terms of a shared state, and also makes it easier to keep the state fully strict and the output lazy. See also: scanlM' Pre-release

  7. smapM :: (IsStream t, Monad m) => (s -> a -> m (s, b)) -> m s -> t m a -> t m b

    streamly Streamly.Internal.Data.Stream.IsStream

    A stateful mapM, equivalent to a left scan, more like mapAccumL. Hopefully, this is a better alternative to scan. Separation of state from the output makes it easier to think in terms of a shared state, and also makes it easier to keep the state fully strict and the output lazy. See also: scanlM' Pre-release

  8. parMapM :: MonadAsync m => (Config -> Config) -> (a -> m b) -> Stream m a -> Stream m b

    streamly Streamly.Internal.Data.Stream.Prelude

    Definition:

    >>> parMapM modifier f = Stream.parConcatMap modifier (Stream.fromEffect . f)
    
    For example, the following finishes in 3 seconds (as opposed to 6 seconds) because all actions run in parallel. Even though results are available out of order they are ordered due to the config option:
    >>> f x = delay x >> return x
    
    >>> Stream.fold Fold.toList $ Stream.parMapM (Stream.ordered True) f $ Stream.fromList [3,2,1]
    1 sec
    2 sec
    3 sec
    [3,2,1]
    

  9. concatMapM :: (IsStream t, Monad m) => (a -> m (t m b)) -> t m a -> t m b

    streamly Streamly.Prelude

    Map a stream producing monadic function on each element of the stream and then flatten the results into a single stream. Since the stream generation function is monadic, unlike concatMap, it can produce an effect at the beginning of each iteration of the inner loop.

  10. sPMapMV :: Stream -> MVar PlayMap

    tidal Sound.Tidal.Boot

    No documentation available.

Page 95 of many | Previous | Next