autoconf
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Problem with exit() and new version of gcc.


From: Pavel Roskin
Subject: Re: Problem with exit() and new version of gcc.
Date: Mon, 18 Dec 2000 01:49:57 -0500 (EST)

Hello, Alexandre!

> > #ifdef __cplusplus
> > #undef exit
> > #define exit(x) return (x)
> > #endif
>
> But what if a hand-coded test calls exit() from some function other
> than main()?

Nothing good, obviously :-(
Ignore my patch, we should make a better one.

We probably should create a table of what declarations work with what
compilers.

                   No declaration   stdlib.h   Simple   Using throw
egcs-1.1.2             Ok              Ok        Ok         Ok
gcc-2.95.2             Ok              Ok        Ok         Ok
gcc-2.97               Ok              Ok       Not Ok      Ok

Can anybody continue? How about commercial compilers?

If there is a declaration that always works we should stick with it.
Otherwise we should check what declaration if preferred for the given
compiler and use it.

Regards,
Pavel Roskin




reply via email to

[Prev in Thread] Current Thread [Next in Thread]