D - Thread.wait()
- "Matthew Wilson" <dmd synesis.com.au> Apr 12 2003
- "Walter" <walter digitalmars.com> Apr 19 2003
Maize
The documentation for Thread says:
void wait();
Wait for this thread to terminate. Throws ThreadError if the thread hasn't
begun yet or has already terminated or is called on itself
Thankfully these are not the semantics apparent in thread.d.
void wait()
{
if (this === getThis())
error("wait on self");
if (state == TS.RUNNING)
{ DWORD dw;
dw = WaitForSingleObject(hdl, 0xFFFFFFFF);
}
}
Presumably the doc is just out-of-date. Is this correct?
Apr 12 2003
I think the doc is wrong. "Matthew Wilson" <dmd synesis.com.au> wrote in message news:b7aftr$s24$1 digitaldaemon.com...Maize The documentation for Thread says: void wait(); Wait for this thread to terminate. Throws ThreadError if the thread hasn't begun yet or has already terminated or is called on itself Thankfully these are not the semantics apparent in thread.d. void wait() { if (this === getThis()) error("wait on self"); if (state == TS.RUNNING) { DWORD dw; dw = WaitForSingleObject(hdl, 0xFFFFFFFF); } } Presumably the doc is just out-of-date. Is this correct?
Apr 19 2003








"Walter" <walter digitalmars.com>