View source code
Display the source code in std/concurrency.d from which this
page was generated on github.
Report a bug
If you spot a problem with this page, click here to create a
Bugzilla issue.
Improve this page
Quickly fork, edit online, and submit a pull request for this page.
Requires a signed-in GitHub account. This works well for small changes.
If you'd like to make larger changes you may want to consider using
local clone.
Function std.concurrency.Scheduler.spawn
Assigns a logical thread to execute the supplied op.
abstract void spawn
(
void delegate() op
);
This routine is called by spawn. It is expected to instantiate a new
logical thread and run the supplied operation. This thread must call
thisInfo
when the thread terminates if the scheduled thread
is not a kernel thread--all kernel threads will have their ThreadInfo
cleaned up automatically by a thread-local destructor.
Parameters
Name | Description |
---|---|
op | The function to execute. This may be the actual function passed by the user to spawn itself, or may be a wrapper function. |
Authors
Sean Kelly, Alex Rønne Petersen, Martin Nowak
License
Copyright © 1999-2024 by the D Language Foundation | Page generated by ddox.