[c++-pthreads] C++ and posix threads
Mark Mitchell
mark at codesourcery.com
Tue Dec 23 16:29:38 UTC 2003
On Tue, 2003-12-23 at 08:03, Ted Baker wrote:
> Am I missing something here?
>
> How do you propose to modify read() to throw an exception and
> still have backwards compatability with applications that expect
> read() to always return (more specifically, to return -1 if it
> fails)?
There are various ways of changing the behavior of a function based on
an "application mode", including environment variables, calls at
start-up time to profile-selection routines, linking with different
versions of libraries, etc. All of these methods are used on various
systems and while you can certainly pick nits about each one, they work
well for most programs most of the time.
But, all that is beside the point, in that it is implementation detail.
The key question is what behavior we would like to see.
The most constructive posting on this list so far has been Nathan's
proposal here:
http://www.codesourcery.com/archives/c++-pthreads/msg00021.html
in that it is a concrete proposal that makes a certain set of tradeoffs.
What I would like to see is not criticism of Nathan's proposal, not
discussion of implementation issues, not discussion of thread support in
ISO C++, but rather alternative proposals for making POSIX threads
interoperate successfully with C++.
Once there are several such proposals on the table, we might be able to
discuss the various strengths and weaknesses between them.
--
Mark Mitchell <mark at codesourcery.com>
CodeSourcery, LLC
More information about the c++-pthreads
mailing list