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: Build of egcs-971031 on m68k-next-nextstep3 fails in libstc++



  In message <9711012250.AA08033@moene.indiv.nluug.nl>you write:
  > In file included from complex:7,
  >                  from std/complext.cc:28,
  >                  from ./cinst.cc:29:
  > std/complext.h:314: declaration of C function `double hypot(double,  
  > double)' conflicts with
  > /NextDeveloper/Headers/ansi/math.h:26: previous declaration `const  
  > double hypot(double, double)' here
Sigh.  This is a bug in the nextstep headers.

They're using the old (and incorrect) method for trying to describe
a "pure" function by prefixing the function's return type with a
"const".

This is wrong because the "const" really applies to the return type,
not the function itself.

The right way to describe a "pure" function is to use an attribute,
but that only works with newer versions of gcc.

Anyway, enough background...

This is something we usually address with fixincludes; I'll see
what I can do if you send me a copy of /NextDeveloper/Headers/ansi/math.h

jeff


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