Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

Is it possible to have a version of forkIO that allows 'thread-objects' to return values?

74 views
Skip to first unread message

Dan

unread,
Feb 10, 2013, 3:55:53 PM2/10/13
to
Ie. a forkIO with type signature IO a -> IO (ThreadId , a)
Can such a thing be implemented without compromising paralelism?

Paul Rubin

unread,
Feb 10, 2013, 4:04:12 PM2/10/13
to
Dan <dan.ms...@gmail.com> writes:
> Ie. a forkIO with type signature IO a -> IO (ThreadId , a)
> Can such a thing be implemented without compromising paralelism?

If I understand the question, usually you would pass the return value
back through an MVar.
Message has been deleted
0 new messages