4 ms·
This makes no sense to me. You are absolutely aware this will happen because you called Rayon's `.par_iter()` method! The pitfalls of parallel and concurrent c
by tatterdemalion 10y ago
This makes no sense to me. You are absolutely aware this will happen because you called Rayon's `.par_iter()` method!
The pitfalls of parallel and concurrent computing are well known, and you are correct should not use a data parallelism library for effectful actions whose order matters. But of course the same concerns can arise when using goroutines.
In contrast, Rust actually does guarantee an absence of data races, in rayon or in any other concurrency or parallelism library, whereas Go provides no such guarantee.
- geoka9 10y agoI know it's not the same, but in Go you can compile with `-race` and it'll catch race conditions at run-time (useful for testing/debugging).