Hoogle Search

Within LTS Haskell 24.9 (ghc-9.10.2)

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

  1. firsting :: forall (f :: Type -> Type -> Type) (g :: Type -> Type -> Type) s t a b x y . (Bifunctor f, Bifunctor g) => AnIso s t a b -> Iso (f s x) (g t y) (f a x) (g b y)

    lens Control.Lens.Iso

    Lift an Iso into the first argument of a Bifunctor.

    firsting :: Bifunctor p => Iso s t a b -> Iso (p s x) (p t y) (p a x) (p b y)
    firsting :: Bifunctor p => Iso' s a -> Iso' (p s x) (p a x)
    

  2. first' :: Strong p => p a b -> p (a, c) (b, c)

    profunctors Data.Profunctor

    Laws:

    first'dimap swap swap . second'
    lmap fstrmap fst . first'
    lmap (second' f) . first'rmap (second' f) . first'
    first' . first'dimap assoc unassoc . first' where
    assoc ((a,b),c) = (a,(b,c))
    unassoc (a,(b,c)) = ((a,b),c)
    

  3. firstRep :: Representable p => p a b -> p (a, c) (b, c)

    profunctors Data.Profunctor.Rep

    Default definition for first' given that p is Representable.

  4. first' :: Strong p => p a b -> p (a, c) (b, c)

    profunctors Data.Profunctor.Strong

    Laws:

    first'dimap swap swap . second'
    lmap fstrmap fst . first'
    lmap (second' f) . first'rmap (second' f) . first'
    first' . first'dimap assoc unassoc . first' where
    assoc ((a,b),c) = (a,(b,c))
    unassoc (a,(b,c)) = ((a,b),c)
    

  5. firstTraversing :: Traversing p => p a b -> p (a, c) (b, c)

    profunctors Data.Profunctor.Traversing

    No documentation available.

  6. firstA :: (Bitraversable t, Applicative f) => (a -> f c) -> t a b -> f (t c b)

    base-compat Data.Bitraversable.Compat

    Traverses only over the first argument.

    firstA f ≡ bitraverse f pure
    

  7. firstJustM :: Monad m => (a -> m (Maybe b)) -> [a] -> m (Maybe b)

    extra Control.Monad.Extra

    Like findM, but also allows you to compute some additional information in the predicate.

  8. firstJustM :: (Foldable f, Monad m) => (a -> m (Maybe b)) -> f a -> m (Maybe b)

    extra Data.Foldable.Extra

    A generalization of firstJustM to Foldable instances.

  9. firstJust :: (a -> Maybe b) -> [a] -> Maybe b

    extra Data.List.Extra

    Find the first element of a list for which the operation returns Just, along with the result of the operation. Like find but useful where the function also computes some expensive information that can be reused. Particular useful when the function is monadic, see firstJustM.

    firstJust id [Nothing,Just 3]  == Just 3
    firstJust id [Nothing,Nothing] == Nothing
    

  10. first3 :: (a -> a') -> (a, b, c) -> (a', b, c)

    extra Data.Tuple.Extra

    Update the first component of a triple.

    first3 succ (1,1,1) == (2,1,1)
    

Page 16 of many | Previous | Next