From: Anthony Williams (anthony.ajw_at_[hidden])
Date: 2008-05-28 10:35:39
Stefan Seefeld <seefeld_at_[hidden]> writes:
> Anthony Williams wrote:
>> OK. t.joinable() /really/ means t represents a thread of
> Out of curiosity: Why do you consider a detached thread not to be a
> "thread of execution" ?
It is a thread of execution, it's just that no thread object can
represent a detached thread.
> I can use all the usual means like mutexes and conditions across
> detached threads, can't I ?
> (And even the 'main' thread is one, as you have stated, even though it's
> impossible to obtain a thread object for it.)
Yes. Exactly like a detached thread.
>> However, the implication of the word is "t can be joined",
>> which is too narrow. t.attached() could indeed be read to mean "not
>> detached", which is also not really correct.
>> t.represents_a_thread() would be strictly correct, but is a bit
>> t.has_thread() is shorter.
> I find these really confusing since the word 'thread' appears in two
> very distinct meanings here. (first as the type of 't', then as "thread
> of execution".)
Yes, I did worry about that. Any more ideas?
-- Anthony Williams | Just Software Solutions Ltd Custom Software Development | http://www.justsoftwaresolutions.co.uk Registered in England, Company Number 5478976. Registered Office: 15 Carrallack Mews, St Just, Cornwall, TR19 7UL
Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk