Hoogle Search
Within LTS Haskell 24.58 (ghc-9.10.3)
Note that Stackage only displays results for the latest LTS and Nightly snapshot. Learn more.
whenJustM :: Monad m => m (Maybe a) -> (a -> m ()) -> m ()relude Relude.Monad.Maybe Monadic version of whenJust.
>>> whenJustM (pure Nothing) $ \b -> print (not b) >>> whenJustM (pure $ Just True) $ \b -> print (not b) False
-
relude Relude.Monad.Reexport The isJust function returns True iff its argument is of the form Just _.
Examples
Basic usage:>>> isJust (Just 3) True
>>> isJust (Just ()) True
>>> isJust Nothing False
Only the outer constructor is taken into consideration:>>> isJust (Just Nothing) True
fromJust :: HasCallStack => Maybe a -> arelude Relude.Unsafe The fromJust function extracts the element out of a Just and throws an error if its argument is Nothing.
Examples
Basic usage:>>> fromJust (Just 1) 1
>>> 2 * (fromJust (Just 10)) 20
>>> 2 * (fromJust Nothing) *** Exception: Maybe.fromJust: Nothing ...
WARNING: This function is partial. You can use case-matching instead.data
IsJust (b :: Maybe a) (c :: Bool)first-class-families Fcf No documentation available.
data
IsJust (b :: Maybe a) (c :: Bool)first-class-families Fcf.Data.Common No documentation available.
adjust :: (a -> a) -> Key a -> Context -> Contexths-opentelemetry-api OpenTelemetry.Context No documentation available.
adjustContext :: MonadIO m => (Context -> Context) -> m ()hs-opentelemetry-api OpenTelemetry.Context.ThreadLocal Alter the context on the current thread using the provided function. If there is not a context associated with the current thread, the function will be applied to an empty context and the result will be stored
adjustContextOnThread :: MonadIO m => ThreadId -> (Context -> Context) -> m ()hs-opentelemetry-api OpenTelemetry.Context.ThreadLocal Alter the context If there is not a context associated with the provided thread, the function will be applied to an empty context and the result will be stored
adjust :: (Eq k, Hashable k) => (v -> v) -> k -> InsOrdHashMap k v -> InsOrdHashMap k vinsert-ordered-containers Data.HashMap.Strict.InsOrd No documentation available.
-
streaming Streaming Repeat a