-
Notifications
You must be signed in to change notification settings - Fork 11
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
MonadPar everywhere #15
Comments
I would have liked to have used |
Is |
The reason I ask this, is that |
I agree it's not ideal. The problem is that in quite a few cases, we really do need to run the two coroutines in parallel, or we won't see effects run until some time later. This isn't just limited to I'm happy to discuss alternative approaches, of course. |
My alternative suggestion would be to just create a separate |
I'd like to avoid duplication of code if possible. For my purposes in Thermite, I can probably fuse coroutines manually, so maybe the best solution is to just go back to the original approach, and provide additional helper functions. For example, one variant on |
#12 is a little problematic, the introduction of
MonadPar
constraints on all the operations really restricts what you can do with coroutines now - you can't even run the examples as they're inEff
instead ofAff
.Additionally, it causes problems in Halogen, as there's no
MonadPar
instance forFree
. I could make something up, but it wouldn't make much sense.Would it possible to have a
fuseWithPar
or something like that for the cases where you really want it, and then restore the previous behaviour for the standard cases?/cc @natefaubion
The text was updated successfully, but these errors were encountered: