This is the mail archive of the libstdc++@gcc.gnu.org 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


>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.

indeed

>Here's a patch for discussion purposes.  It installs a libverbose_terminate,
>and I've verified by hand that using -lverbose_terminate or LD_PRELOAD
>both DTRT.  I've made an attempt at a testcase, but dg-output doesn't do
>what I thought it did; the testsuite log shows
>
>    PASS: ext/verbose_terminate.cc (test for excess errors)
>    terminate called after throwing a `int'
>    FAIL: ext/verbose_terminate.cc execution test
>
>                    === libstdc++-v3 Summary ===
>
>    # of expected passes            1
>    # of unexpected failures        1

don't know about this

>2002-12-19  Phil Edwards  <pme@gcc.gnu.org>
>
>	* src/verb_term.cc:  New file.

there is already a vterminate.cc, so adding something like verb_term or
whatever seems confusing.

>+namespace __gnu_cxx
>+{
>+  static struct __Verb_Term_Preload
>+  {
>+    __Verb_Term_Preload ()
>+      { std::set_terminate (__gnu_cxx::__verbose_terminate_handler); }
>+  } __verb_term_dummy;
>+}

this is yet another naming convention. Please think about using

__[a-z]* or _[A-Z]*

-benjamin


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