From: bill_kempf (williamkempf_at_[hidden])
Date: 2002-01-20 15:16:47
--- In boost_at_y..., "Peter Dimov" <pdimov_at_m...> wrote:
> From: "bill_kempf" <williamkempf_at_h...>
> > I've uploaded the draft document for the next generation of
> > boost::thread for discussion.
> One thing that immediately jumps at me is:
> Requires: category() != foreign and there has been no previous
> either join() or detach() on any thread objects representing the
> of execution as *this.
> but I (the user) have no means to detect whether the requirements
To detect, no, but know, possibly. It depends heavily on the design
of the application.
> It's usually better to make preconditions assert'able in user code;
> sometimes this cannot be done, of course, and if this is the case
> might deserve mention in the documentation.
It can't be detected, so it can't be asserted. Only careful program
design can insure the preconditions in this case. I'll see if I can
work on the documentation to make this clear.
> Another thing that I find somewhat unclear is what is a default
> thread's category.
That totally depends on how the thread was created and whether or not
adopt() has been previously called on it. This is indirectly
documented, but I may need to make it more clear.
Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk