Hoogle Search

Within LTS Haskell 24.38 (ghc-9.10.3)

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

  1. data SMaybe (sa :: a -> Type) (ma :: Maybe a)

    singleraeh Singleraeh.Maybe

    Singleton Maybe.

  2. class SingMaybe (ca :: ak -> Constraint) (sa :: ak -> Type) (ma :: Maybe ak)

    singleraeh Singleraeh.Maybe

    No documentation available.

  3. singMaybe' :: SingMaybe ca sa ma => (forall (a :: ak) . ca a => sa a) -> SMaybe sa ma

    singleraeh Singleraeh.Maybe

    No documentation available.

  4. hMaybeErr :: Handle -> Maybe Handle

    smtlib-backends-process SMTLIB.Backends.Process

    The error channel of the process.

  5. catMaybes :: forall (m :: Type -> Type) a b . Monad m => Fold m a b -> Fold m (Maybe a) b

    streamly-core Streamly.Data.Fold

    Modify a fold to receive a Maybe input, the Just values are unwrapped and sent to the original fold, Nothing values are discarded.

    >>> catMaybes = Fold.mapMaybe id
    
    >>> catMaybes = Fold.filter isJust . Fold.lmap fromJust
    

  6. mapMaybe :: forall (m :: Type -> Type) a b r . Monad m => (a -> Maybe b) -> Fold m b r -> Fold m a r

    streamly-core Streamly.Data.Fold

    mapMaybe f fold maps a Maybe returning function f on the input of the fold, filters out Nothing elements, and return the values extracted from Just.

    >>> mapMaybe f = Fold.lmap f . Fold.catMaybes
    
    >>> mapMaybe f = Fold.mapMaybeM (return . f)
    
    >>> f x = if even x then Just x else Nothing
    
    >>> fld = Fold.mapMaybe f Fold.toList
    
    >>> Stream.fold fld (Stream.enumerateFromTo 1 10)
    [2,4,6,8,10]
    

  7. scanMaybe :: forall (m :: Type -> Type) a b c . Monad m => Fold m a (Maybe b) -> Fold m b c -> Fold m a c

    streamly-core Streamly.Data.Fold

    Use a Maybe returning fold as a filtering scan.

    >>> scanMaybe p f = Fold.postscan p (Fold.catMaybes f)
    
    Pre-release

  8. catMaybes :: forall (m :: Type -> Type) a . Monad m => Stream m (Maybe a) -> Stream m a

    streamly-core Streamly.Data.Stream

    In a stream of Maybes, discard Nothings and unwrap Justs.

    >>> catMaybes = Stream.mapMaybe id
    
    >>> catMaybes = fmap fromJust . Stream.filter isJust
    
    Pre-release

  9. mapMaybe :: forall (m :: Type -> Type) a b . Monad m => (a -> Maybe b) -> Stream m a -> Stream m b

    streamly-core Streamly.Data.Stream

    Map a Maybe returning function to a stream, filter out the Nothing elements, and return a stream of values extracted from Just. Equivalent to:

    >>> mapMaybe f = Stream.catMaybes . fmap f
    

  10. mapMaybeM :: Monad m => (a -> m (Maybe b)) -> Stream m a -> Stream m b

    streamly-core Streamly.Data.Stream

    Like mapMaybe but maps a monadic function. Equivalent to:

    >>> mapMaybeM f = Stream.catMaybes . Stream.mapM f
    
    >>> mapM f = Stream.mapMaybeM (\x -> Just <$> f x)
    

Page 251 of many | Previous | Next