Is there any good explanation or guide with examples of how to write correct multi-threaded code in D using shared, synchronized, core.sync.* etc things?
How to write correct multi-threaded code?
Andrey Zherikov via Digitalmars-d-learn Wed, 16 Oct 2019 06:50:55 -0700
I'm trying to write multi-threaded code that uses mutexes,
condition variables and atomics but I've got confused how to do
this correctly. Everything I found so far include a lot of
casting to/from shared even for the objects that are supposed to
be shared (like mutex and condition variable).