Hoogle Search

Within LTS Haskell 24.51 (ghc-9.10.3)

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

  1. adjust :: (Ord k, Ord (Tag v), HasTag v) => (v -> v) -> k -> BiMap k v -> BiMap k v

    Agda Agda.Utils.BiMap

    Modifies the value at the given position, if any. O(log n). Precondition: See adjustPrecondition.

  2. adjustPrecondition :: (Ord k, Eq v, Eq (Tag v), HasTag v) => (v -> v) -> k -> BiMap k v -> Bool

    Agda Agda.Utils.BiMap

    The precondition for adjust f k m is that, if the value v is inserted into m, and tag v is defined, then no key other than k may map to a value v' for which tag v' = tag v.

  3. applyWhenJust :: Maybe b -> (b -> a -> a) -> a -> a

    Agda Agda.Utils.Function

    Maybe version of applyWhen.

  4. catchImpossibleJust :: CatchImpossible m => (Impossible -> Maybe b) -> m a -> (b -> m a) -> m a

    Agda Agda.Utils.Impossible

    Catch only Impossible exceptions selected by the filter.

  5. handleImpossibleJust :: CatchImpossible m => (Impossible -> Maybe b) -> (b -> m a) -> m a -> m a

    Agda Agda.Utils.Impossible

    Version of catchImpossibleJust with argument order suiting short handlers.

  6. spanJust :: (a -> Maybe b) -> [a] -> (Prefix b, Suffix a)

    Agda Agda.Utils.List

    A generalized version of span. O(length . fst . spanJust f).

  7. takeWhileJust :: (a -> Maybe b) -> [a] -> Prefix b

    Agda Agda.Utils.List

    A generalized version of takeWhile. (Cf. mapMaybe vs. filter). @O(length . takeWhileJust f). takeWhileJust f = fst . spanJust f.

  8. adjustM :: (Functor f, Ord k) => (v -> f v) -> k -> Map k v -> f (Map k v)

    Agda Agda.Utils.Map

    Update monadically the value at one position (must exist!).

  9. adjustM' :: (Functor f, Ord k) => (v -> f (a, v)) -> k -> Map k v -> f (a, Map k v)

    Agda Agda.Utils.Map

    Wrapper for adjustM for convenience.

  10. allJustM :: Monad m => [m (Maybe a)] -> m (Maybe [a])

    Agda Agda.Utils.Maybe

    Lazy version of allJust . sequence. (allJust = mapM for the Maybe monad.) Only executes monadic effect while isJust.

Page 118 of many | Previous | Next