[Haskell-cafe] a parallel mapM?

Ozgur Akgun ozgurakgun at gmail.com
Sun Oct 7 18:07:32 CEST 2012


On 3 October 2012 19:23, Ryan Newton <rrnewton at gmail.com> wrote:

> That said, I don't see a reason for not including a separate version of
>> runParIO :: ParIO a -> IO a for non-deterministic computations. It seems
>> really useful!
> Exactly.  I should have been more explicit but that's what I meant about
> "adding another module".  You would import Control.Monad.Par.IO and get
> runParIO + liftIO but NOT runPar.  This requires doing a newtype over Par
> to create the liftIO instance for one and not the other (and preserve Safe
> Haskell).  It's a pain but it's no problem.  Both types
> Control.Monad.Par.Par and Control.Monad.Par.IO.ParIO will expose the same
> interface (i.e. have instances of the same classes -- ParFuture,
> ParIVar...), so generic algorithms like "parMap" will still work for either.
>   -Ryan

This sounds like a great idea, I just wanted to ask if anyone is working on
it or not?

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.haskell.org/pipermail/haskell-cafe/attachments/20121007/2b7ed773/attachment.htm>

More information about the Haskell-Cafe mailing list