Boost logo

Boost :

From: William E. Kempf (williamkempf_at_[hidden])
Date: 2002-08-12 18:42:04


----- Original Message -----
From: "Eric Woodruff" <Eric.Woodruff_at_[hidden]>
> Since you now seem willing to allow this non-default option to be made
> available, what kind of interface do you suppose it should have? Should it
> be called asynchronous_call? advanced_thread?

boost::thread. As for the interface, that's still something to work out.

> In any case, it should just be a wrapper of the existing boost::thread, in
> my opinion, because a non-templated implementation is necessary and
there's
> no reason we can't use the pre-existing thread object. Inheritance from
> boost::thread is probably out of the question because it introduces the
> possiblity that a user might mix threads with non-uniform policies. It is
> also unclear how to handle a pool of threads that may throw exceptions on
> join.

The existing boost::thread is going to undergo several changes in Rev. 2,
some of which pretty much mandate a PIMPL idiom, so making the public
interface a template will be trivial.

> Is it at all possible to rename the current boost::thread class to
> boost::basic_thread and supplant the template in its place? (Old users of
> thread would have to change it to thread<> or just use basic_thread.) This
> may deprecate the usage of the current boost::thread class because the
same
> functionality is acheived with thread<>.

basic_thread will be boost::detail::thread_impl and not in the user's public
interface. The switch to a templated thread would, indeed, but a
non-backwards compatible change, unfortunately, and that's one reason I said
the interface was still up to debate.

Bill Kempf


Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk