Actor model & D
Ali Çehreli
acehreli at yahoo.com
Thu Nov 7 09:45:54 PST 2013
On 11/05/2013 07:20 AM, Ali Çehreli wrote:
> On 11/05/2013 04:28 AM, Bienlein wrote:
>
> > Tid worker = spawn(&workerFunc, thisTid);
>
> Going totally off topic here, there is ownerTid in every worker's
> context. (I suspect it was a relatively recent addition.) So, there is
> no need to pass the owner's tid explicitly:
>
> Tid worker = spawn(&workerFunc);
>
> Then the worker uses the available ownerTid:
>
> ownerTid.send(2);
>
> I will simplify those examples.
Done:
http://ddili.org/ders/d.en/concurrency.html
Ali
More information about the Digitalmars-d
mailing list