This is the mail archive of the mailing list for the libstdc++ project.

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: libverbose_terminate, pass 1 of N

On Fri, Dec 20, 2002 at 07:43:40PM -0800, Nathan Myers wrote:
> On Sat, Dec 21, 2002 at 03:26:14AM +0100, Gabriel Dos Reis wrote:
> > Phil Edwards <> writes:
> > 
> > | Jason's patch
> > | 
> > |
> > | 
> > | started an interesting thread of about a dozen messages.  The upshot is that
> > | currently, using __verbose_terminate() as the termination handler requires a
> > | change to user code, usually main().  It Would Be Cool[tm] if the user could
> > | install this handler at link-time with -l, or at runtime with LD_PRELOAD.
> Have we established that a verbose-termination-by-default would not
> be conformant?  Is there some other reason not to want it as the
> default?

Verbose termination calls fprintf, which can't be used in a freestanding
environment.  If -ffreestanding (or whatever it is) were to cause a macro
to be defined, then I see no reason why we couldn't do

    // libsupc++/
    std::terminate_handler __cxxabiv1::__terminate_handler =
    #if freestanding

The only note I can find in the standard is "default terminate() calls
abort," which doesn't seem to preclude also doing other actions.


I would therefore like to posit that computing's central challenge, viz. "How
not to make a mess of it," has /not/ been met.
                                                 - Edsger Dijkstra, 1930-2002

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]