This is the mail archive of the libc-hacker@sourceware.cygnus.com mailing list for the glibc project.

Note that libc-hacker is a closed list. You may look at the archives of this list, but subscription and posting are not open.


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

Re: Your g++ breaks glibc.


> 
> >>>>> "Jeffrey" == Jeffrey A Law <law@cygnus.com> writes:
> 
>     Jeffrey> I've got conflicting reports from Jason and Alexandre
>     Jeffrey> about this one.  I need a definitive answer before I wake
>     Jeffrey> up in the morning or it will not be in gcc-2.95.
> 
> Both Jason and Alexandre are right.
> 
> The code is indeed buggy:
> 
>   [except.spec]
> 
>   If any declaration of a function has an exception-specification, all
>   declarations, including the definition and an explicit specialization,
>   of  that  function shall have an exception-specification with the same
>   set of type-ids.
> 
> It couldn't be any clearer.
> 
> If autoconf is generating the code fragment H.J. shows, then autoconf
> is broken.
> 
> However, the patch should still go on the branch.  After all, autoconf
> is in widespread use.  There is no non-conformance issue here since we
> will still warn if -pedantic.
> 
> H.J., please follow up with whatever tool is producing this bogus
> code, and get that tool fixed.  In the next major version, we should
> 

It is ncurses 4.2. However, I believe the problem is in autoconf and
I don't even know if there is a reasonable fix for autoconf since
it may not know which one,

extern "C" void exit(int);
extern "C" void exit(int) throw ();

to use for a given system. gcc 2.95 works with

#include <stdlib.h>
extern "C" void exit(int);

but not

extern "C" void exit(int);
#include <stdlib.h>

I don't see any reason to allow one and not the other.


H.J.

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