Hoogle Search
Within LTS Haskell 24.4 (ghc-9.10.2)
Note that Stackage only displays results for the latest LTS and Nightly snapshot. Learn more.
-
matrices Data.Matrix.Generic No documentation available.
sequence :: (Traversable t, Monad m) => t (m a) -> m (t a)prelude-compat Prelude2010 Evaluate each monadic action in the structure from left to right, and collect the results. For a version that ignores the results see sequence_.
Examples
Basic usage: The first two examples are instances where the input and and output of sequence are isomorphic.>>> sequence $ Right [1,2,3,4] [Right 1,Right 2,Right 3,Right 4]
>>> sequence $ [Right 1,Right 2,Right 3,Right 4] Right [1,2,3,4]
The following examples demonstrate short circuit behavior for sequence.>>> sequence $ Left [1,2,3,4] Left [1,2,3,4]
>>> sequence $ [Left 0, Right 1,Right 2,Right 3,Right 4] Left 0
sequence :: Monad m => Vector (m a) -> m (Vector a)rebase Rebase.Data.Vector No documentation available.
sequence :: (Monad m, Vector v a, Vector v (m a)) => v (m a) -> m (v a)rebase Rebase.Data.Vector.Generic No documentation available.
sequence :: Functor f => f (T a) -> T (f a)synthesizer-core Synthesizer.Frame.Stereo No documentation available.
sequence :: (Vector v a, Vector v (f a), Applicative f) => v (f a) -> f (v a)fixed-vector Data.Vector.Fixed Evaluate every action in the vector from left to right.
-
fixed-vector Data.Vector.Fixed.Cont Evaluate every action in the vector from left to right.
sequence :: (Traversable t, Monad m) => t (m a) -> m (t a)mixed-types-num Numeric.MixedTypes.PreludeHiding Evaluate each monadic action in the structure from left to right, and collect the results. For a version that ignores the results see sequence_.
Examples
Basic usage: The first two examples are instances where the input and and output of sequence are isomorphic.>>> sequence $ Right [1,2,3,4] [Right 1,Right 2,Right 3,Right 4]
>>> sequence $ [Right 1,Right 2,Right 3,Right 4] Right [1,2,3,4]
The following examples demonstrate short circuit behavior for sequence.>>> sequence $ Left [1,2,3,4] Left [1,2,3,4]
>>> sequence $ [Left 0, Right 1,Right 2,Right 3,Right 4] Left 0
sequence :: Monad m => NonEmptyVector (m a) -> m (NonEmptyVector a)nonempty-vector Data.Vector.NonEmpty Evaluate each action and collect the results
sequence :: forall m (p :: k -> Type) . (Traversable g, Applicative m) => g (Compose m p) -> m (g p)rank2classes Rank2 No documentation available.