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: namespace issues with old C headers


David Schultz <das at freebsd dot org> writes:

[...]

| Note that things work fine if <math.h> is included without
| <cmath>, but if <cmath> is ever included directly or indirectly,

Here is what the C++ standard say (D.5 which I already pointed you at):

  Each C header, whose name has the form name.h, behaves as if each name
  placed in the Standard library namespace by the corresponding cname
  header is also placed within the namespace scope of the name-space std
  and is followed by an explicit using-declaration (7.3.3).

Bringing C99 stuff into C++1998 or C++2003 is sort of extension and we
need to do it in a rational way compatible with the existing. To have
an idea of how those features might get their way into the next major
revision of C++, see: 

   http://anubis.dkuug.dk/jtc1/sc22/wg21/docs/papers/2003/n1444.html#1
   http://std.dkuug.dk/jtc1/sc22/wg21/docs/papers/2002/n1354.txt

-- Gaby


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