3 ms·
> but refs and STM, to me (ie YMMV) seem like one of those things that seemed like a useful great idea, that in practice just wasn’t really necessary. Haskelle
by ParetoOptimal 4y ago
> but refs and STM, to me (ie YMMV) seem like one of those things that seemed like a useful great idea, that in practice just wasn’t really necessary.
Haskellers (including myself) tend to default to STM to take advantage of atomicity.
Of course it's easy to make the safe choice when the shared interface between concurrency primitives make switching very low cost.
More: https://www.oreilly.com/library/view/parallel-and-concurrent/9781449335939/ch10.html https://www.oreilly.com/library/view/parallel-and-concurrent...