How to call stop from parallel foreach

seany seany at uni-bonn.de
Thu Jun 24 20:08:06 UTC 2021


On Thursday, 24 June 2021 at 19:46:52 UTC, Jerry wrote:
> On Thursday, 24 June 2021 at 18:23:01 UTC, seany wrote:
>> [...]
>
> Maybe I'm wrong here, but I don't think there is any way to do 
> that with parallel.
> What I would do is negate someConditionCheck and instead only 
> do work when there is work to be done.
> Obviously that may or may not be suitable.
> But with parallel I don't see any way to make it happen.

The parallel() function is running a taskpool. I should be able 
to stop that in any case...


More information about the Digitalmars-d-learn mailing list