On Nov 22, 2007, at 13:17 , Maurí cio wrote:
If I have two computations a->IO b and b->IO c, can I join them to get an a->IO c computation? I imagine something like a liftM dot operator.
If you have GHC 6.8.1, this is the Kleisli composition operator (>=>) in Control.Monad. (There is also (<=<) which corresponds to (=<<).)
Prelude Control.Monad> :i (>=>) (>=>) :: (Monad m) => (a -> m b) -> (b -> m c) -> a -> m c -- Defined in Control.Monad infixr 1 >=> Prelude Control.Monad> :i (<=<) (<=<) :: (Monad m) => (b -> m c) -> (a -> m b) -> a -> m c -- Defined in Control.Monad infixr 1 <=< -- brandon s. allbery [solaris,freebsd,perl,pugs,haskell] [EMAIL PROTECTED] system administrator [openafs,heimdal,too many hats] [EMAIL PROTECTED] electrical and computer engineering, carnegie mellon university KF8NH _______________________________________________ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe