Boost logo

Boost :

From: Alexander Terekhov (terekhov_at_[hidden])
Date: 2001-08-22 07:41:12

> Another question:
> How do I create a 'joinable' thread object representing the main thread?

AFAICT you cannot. however, Bill can probably do it
for you using some internal thread-safe singleton
and public static thread& thread::main() method..
i really do not like the current design. i do like
thread& thread::currect() which would also work
with respect to main thread.

and again, you do not really need smart pointers
for "only one thread object per thread" design.
smart thread::ref design would give us implicit
life time management for dynamic thread objects.
but i also want to be able to do it explicitly
via new/delete/detach and via auto/static storage
duration (non-detachable, auto-join on destruction).
i think that smart thread::ref design is really
optional (add-on/nice to have feature).


Boost list run by bdawes at, gregod at, cpdaniel at, john at