On Tue, Jul 20, 2021 at 01:07:22AM +0000, seany via Digitalmars-d-learn wrote:
> On Tuesday, 20 July 2021 at 00:37:56 UTC, H. S. Teoh wrote:
> > On Tue, Jul 20, 2021 at 12:07:10AM +0000, seany via Digitalmars-d-learn
> > wrote:
> > > [...]
> > [...]
> > 
> > I didn't test this, but I'm pretty sure `continue` inside a parallel
> > foreach loop simply terminates that iteration early; I don't think
> > it will skip to the next iteration.
> > 
> > [...]
> 
> Ok, therefore it means that, if at `j = 13 `i use a continue, then the
> thread where I had `10`... `20` as values of `j`, will only execute
> for `j = 10, 11, 12 ` and will not reach `14`or later ?

No, it will.

Since each iteration is running in parallel, the fact that one of them
terminated early should not affect the others.


T

-- 
Skill without imagination is craftsmanship and gives us many useful objects 
such as wickerwork picnic baskets.  Imagination without skill gives us modern 
art. -- Tom Stoppard

Reply via email to