Hoogle Search

Within LTS Haskell 24.6 (ghc-9.10.2)

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

  1. mapMaybe :: (MonadGen m, GenBase m ~ Identity) => (a -> Maybe b) -> m a -> m b

    hedgehog Hedgehog.Gen

    Generates a value which is the result of the given function returning a Just. The original generator's shrink tree will be retained, with values returning Nothing removed. Subsequent shrinks of those values will be retained. Compared to mapMaybeT, shrinking may be slower but will be optimal. It's possible that the function will never return Just, or will only do so a larger size than we're currently running at. To avoid looping forever, we limit the number of retries, and grow the size with each retry. If we retry too many times then the whole generator is discarded.

  2. mapMaybeT :: MonadGen m => (a -> Maybe b) -> m a -> m b

    hedgehog Hedgehog.Gen

    Generates a value which is the result of the given function returning a Just. The original generator's shrink tree will be retained, with values returning Nothing removed. Subsequent shrinks of those values will be retained. Compared to mapMaybeT, shrinking may be slower but will be optimal. The type is also more general, because the shrink behavior from mapMaybe would force the entire shrink tree to be evaluated when applied to an impure tree. It's possible that the function will never return Just, or will only do so a larger size than we're currently running at. To avoid looping forever, we limit the number of retries, and grow the size with each retry. If we retry too many times then the whole generator is discarded.

  3. mapGenT :: forall (m :: Type -> Type) a (n :: Type -> Type) b . (TreeT (MaybeT m) a -> TreeT (MaybeT n) b) -> GenT m a -> GenT n b

    hedgehog Hedgehog.Internal.Gen

    Map over a generator's shrink tree.

  4. mapMaybe :: (MonadGen m, GenBase m ~ Identity) => (a -> Maybe b) -> m a -> m b

    hedgehog Hedgehog.Internal.Gen

    Generates a value which is the result of the given function returning a Just. The original generator's shrink tree will be retained, with values returning Nothing removed. Subsequent shrinks of those values will be retained. Compared to mapMaybeT, shrinking may be slower but will be optimal. It's possible that the function will never return Just, or will only do so a larger size than we're currently running at. To avoid looping forever, we limit the number of retries, and grow the size with each retry. If we retry too many times then the whole generator is discarded.

  5. mapMaybeT :: MonadGen m => (a -> Maybe b) -> m a -> m b

    hedgehog Hedgehog.Internal.Gen

    Generates a value which is the result of the given function returning a Just. The original generator's shrink tree will be retained, with values returning Nothing removed. Subsequent shrinks of those values will be retained. Compared to mapMaybeT, shrinking may be slower but will be optimal. The type is also more general, because the shrink behavior from mapMaybe would force the entire shrink tree to be evaluated when applied to an impure tree. It's possible that the function will never return Just, or will only do so a larger size than we're currently running at. To avoid looping forever, we limit the number of retries, and grow the size with each retry. If we retry too many times then the whole generator is discarded.

  6. mapM :: (Traversable t, Monad m) => (a -> m b) -> t a -> m (t b)

    hedgehog Hedgehog.Internal.Prelude

    Map each element of a structure to a monadic action, evaluate these actions from left to right, and collect the results. For a version that ignores the results see mapM_.

    Examples

    mapM is literally a traverse with a type signature restricted to Monad. Its implementation may be more efficient due to additional power of Monad.

  7. mapM_ :: (Foldable t, Monad m) => (a -> m b) -> t a -> m ()

    hedgehog Hedgehog.Internal.Prelude

    Map each element of a structure to a monadic action, evaluate these actions from left to right, and ignore the results. For a version that doesn't ignore the results see mapM. mapM_ is just like traverse_, but specialised to monadic actions.

  8. mappend :: Monoid a => a -> a -> a

    hedgehog Hedgehog.Internal.Prelude

    An associative operation NOTE: This method is redundant and has the default implementation mappend = (<>) since base-4.11.0.0. Should it be implemented manually, since mappend is a synonym for (<>), it is expected that the two functions are defined the same way. In a future GHC release mappend will be removed from Monoid.

  9. mapConfig :: (PropertyConfig -> PropertyConfig) -> Property -> Property

    hedgehog Hedgehog.Internal.Property

    Map a config modification function over a property.

  10. mapMaybe :: (a -> Maybe b) -> Tree a -> Maybe (Tree b)

    hedgehog Hedgehog.Internal.Tree

    No documentation available.

Page 81 of many | Previous | Next