is increment on shared ulong atomic operation?

Andrea Fontana via Digitalmars-d-learn digitalmars-d-learn at puremagic.com
Mon Feb 8 00:33:40 PST 2016


On Sunday, 7 February 2016 at 20:25:44 UTC, Minas Mina wrote:
>> Just noticed that there's no example.
>> It's used like
>>
>> shared(ulong) a;
>> atomicOp!"+="(a, 1);
>
> Wow, that syntax sucks a lot.


a.atomicOp!"+="(1);

sounds better. You can alias it too.



More information about the Digitalmars-d-learn mailing list