Open dlangBugzillaToGithub opened 9 years ago
> it is sufficient for the context to be const, otherwise it probably needs to be immutable.
`i` should be declared `shared` for safe mutation. To support that, the ParallelForeach.opApply delegate context parameter should require `shared` (which would allow `immutable` too). Unfortunately the opApply delegate doesn't support `shared` (or `immutable`) context inference AFAICT.
Both of these are examples of possible data races that should've been detected:
https://issues.dlang.org/show_bug.cgi?id=23624
https://issues.dlang.org/show_bug.cgi?id=23634
schuetzm (schuetzm) reported this on 2015-09-30T08:40:40Z
Transfered from https://issues.dlang.org/show_bug.cgi?id=15129
CC List
Description