[Bug 28] New: Documentation

d-bugmail at puremagic.com d-bugmail at puremagic.com
Thu Mar 9 06:34:31 PST 2006


http://d.puremagic.com/bugzilla/show_bug.cgi?id=28

           Summary: Documentation
           Product: D
           Version: unspecified
          Platform: PC
               URL: http://www.digitalmars.com/d/phobos/std_thread.html
        OS/Version: Windows
            Status: NEW
          Severity: normal
          Priority: P2
         Component: Phobos
        AssignedTo: braddr at puremagic.com
        ReportedBy: benoit at tionex.de


In the specification/doc of std.thread:

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.

The implementation does throw an exception if called on itself: OK
The implementation does throw an exception if pthread_join does not succeed: OK

But throwing an exception if the thread is allready terminated not implemented
nor would this be useful - you cannot check that the thread is running and be
sure that until calling the .wait, the thread does not terminate.

So, like it is implemented, wait should return without exception if the thread
is terminated.


-- 




More information about the Digitalmars-d-bugs mailing list