I'm porting some go code to D

Timon Gehr timon.gehr at gmx.ch
Sun Aug 25 16:21:19 PDT 2013


On 08/26/2013 12:55 AM, Rory McGuire wrote:
>
> shared chan!Fiber scheduler; // channel contains Fibers waiting for
> their time slice
> static this () {
>      if (scheduler is null) {


You want 'shared static this' instead to avoid a race condition.


More information about the Digitalmars-d-announce mailing list