Hoogle Search
Within LTS Haskell 24.4 (ghc-9.10.2)
Note that Stackage only displays results for the latest LTS and Nightly snapshot. Learn more.
forkOSWithUnmask :: ((forall a . () => IO a -> IO a) -> IO ()) -> IO ThreadIdbase Control.Concurrent Like forkIOWithUnmask, but the child thread is a bound thread, as with forkOS.
forkOn :: Int -> IO () -> IO ThreadIdbase Control.Concurrent Like forkIO, but lets you specify on which capability the thread should run. Unlike a forkIO thread, a thread created by forkOn will stay on the same capability for its entire lifetime (forkIO threads can migrate between capabilities according to the scheduling policy). forkOn is useful for overriding the scheduling policy when you know in advance how best to distribute the threads. The Int argument specifies a capability number (see getNumCapabilities). Typically capabilities correspond to physical processors, but the exact behaviour is implementation-dependent. The value passed to forkOn is interpreted modulo the total number of capabilities as returned by getNumCapabilities. GHC note: the number of capabilities is specified by the +RTS -N option when the program is started. Capabilities can be fixed to actual processor cores with +RTS -qa if the underlying operating system supports that, although in practice this is usually unnecessary (and may actually degrade performance in some cases - experimentation is recommended).
forkOnWithUnmask :: Int -> ((forall a . () => IO a -> IO a) -> IO ()) -> IO ThreadIdbase Control.Concurrent Like forkIOWithUnmask, but the child thread is pinned to the given CPU, as with forkOn.
forM_ :: (Foldable t, Monad m) => t a -> (a -> m b) -> m ()base Data.Foldable forM_ is mapM_ with its arguments flipped. For a version that doesn't ignore the results see forM. forM_ is just like for_, but specialised to monadic actions.
for_ :: (Foldable t, Applicative f) => t a -> (a -> f b) -> f ()base Data.Foldable for_ is traverse_ with its arguments flipped. For a version that doesn't ignore the results see for. This is forM_ generalised to Applicative actions. for_ is just like forM_, but generalised to Applicative actions.
Examples
Basic usage:>>> for_ [1..4] print 1 2 3 4
forAccumM :: (Monad m, Traversable t) => s -> t a -> (s -> a -> m (s, b)) -> m (s, t b)base Data.Traversable forM :: (Traversable t, Monad m) => t a -> (a -> m b) -> m (t b)base Data.Traversable forM is mapM with its arguments flipped. For a version that ignores the results see forM_.
formatArg :: PrintfArg a => a -> FieldFormatterbase Text.Printf No documentation available.
formatChar :: Char -> FieldFormatterbase Text.Printf Formatter for Char values.
formatInt :: (Integral a, Bounded a) => a -> FieldFormatterbase Text.Printf Formatter for Int values.