This is the mail archive of the gcc@gcc.gnu.org mailing list for the GCC project.


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

Re: egcs 10-31 and UnixWare


> Has the committee clarified this?  I can think of two logical ways
> to proceed: call terminate(), or ignore the second exit() call.

I can think of yet another: finish processing the current destructor,
but continue with the remaining ones.  There are two obvious ways
to implement it:

 - set a flag when destructor processing begins, make a setjmp
  in the loop that processes the destructors, and when there is
  an exit() recursion, do a longjmp.

- use (a) non-local variable(s) to interate through the destructors,
and allow full recursion of exit, but arrange the processing of the
iteration variables so that the next destructor will be picked as the
first one in the recursive call.


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