Monad combinators, as in Haskell's Control.Monad. #
Equations
- Monad.sequence [] = pure []
- Monad.sequence (h :: t) = do let h' ← h let t' ← Monad.sequence t pure (h' :: t')
Instances For
Equations
- Monad.sequence' [] = pure ()
- Monad.sequence' (h :: t) = h *> Monad.sequence' t