Passing arguments to a new thread
timon.gehr at gmx.ch
Fri Jan 20 07:33:33 PST 2012
On 01/20/2012 03:12 PM, Mars wrote:
> Hello everybody.
> As the title states, I want to run a function in a new thread, and pass
> it some arguments. How would I do that? I guess I could make a class,
> deriving from Thread, and work with it, but out of curiosity, I'd like
> to know if it's possible with a simple function.
auto tid = spawn(&function, arg1, arg2, arg3, ...);
More information about the Digitalmars-d-learn