On Sunday, 31 August 2025 at 22:53:51 UTC, Steven Schveighoffer
wrote:
`std.concurrency` is meant to make all these control flow
systems easy to avoid races for, even in `@safe` code. Sending
the boolean instead of keeping a pointer to a shared boolean
can alleviate a lot of these problems.
On Sunday, 31 August 2025 at 12:44:33 UTC, Brother Bill wrote:
On Sunday, 31 August 2025 at 01:27:57 UTC, Steven Schveighoffer
wrote:
Why would your second iteration make a difference? Purely by
chance! In fact, on my machine, it does not exit in either
case.
Welcome to the wonderful world of
On Sunday, 31 August 2025 at 12:44:33 UTC, Brother Bill wrote:
FWIW, given that D supports Message Passing Concurrency, is
Data Sharing Concurrency just there for D completeness, for
those that want to live close to the iron.
Speaking as a guy who did Unix kernel SMP for years, there are
time
On Sunday, 31 August 2025 at 01:27:57 UTC, Steven Schveighoffer
wrote:
Why would your second iteration make a difference? Purely by
chance! In fact, on my machine, it does not exit in either case.
Welcome to the wonderful world of race conditions and
multithreading!
So this was just 'bad' lu
On Saturday, 30 August 2025 at 22:05:49 UTC, Brother Bill wrote:
A predicate (!*isDone) vs. (*isDone == false) seems to have
different behavior, where I would expect identical behavior.
What am I missing?
This program runs forever, even though isDone changes from
false to true.
```d
import
A predicate (!*isDone) vs. (*isDone == false) seems to have
different behavior, where I would expect identical behavior.
What am I missing?
This program runs forever, even though isDone changes from false
to true.
```
import std.stdio;
import std.concurrency;
import core.thread;
import core.