News for hackers. Stuff that matters.
Re:Go Statement Considered Harmful (2018) by eru on Friday March 19, 2021 @03:10AM (#26510732)
Yes, that would be neat.

Trio's nurseries remind a little bit of IO in Haskell.

Forgetting all about Monads etc, you can re-interpret IO-typing in Haskell as the requirement to keep carry something like a 'nursery' around with your code. Parts of code that don't have access to such a 'nursery'-like object can't do IO. (And because it's Haskell, that access is also tracked in the types.)

Re:Go Statement Considered Harmful (2018) by samprotas on Friday March 19, 2021 @02:16PM (#26516660)
It’s also very directly related the to “effectively standard” (but not included) async library in Haskell.

https://hackage.haskell.org/package/async

The package description at the top of the link touches on the motivations which basically mirror this article.

I’ve personally never reached for the built in forkIO. withAsync or it’s helpers like mapConcurrently are always equally capable, easier to use, and with none of the foot guns.