[RFC] "C" header options

Mark Mitchell mark@codesourcery.com
Thu Jun 7 23:50:00 GMT 2001


>>>>> "Benjamin" == Benjamin Kosnik <bkoz@redhat.com> writes:

    Benjamin> The way I see it, the following options exist:

Thanks for working on this.

I'm not smart enough to quite follow all these options.  Can you give
an example of what (say) strlen would look like in each of these
cases, both for <string.h> and for <cstring>?

I was hoping that the <cstring> that does:

  #include <string.h>

  namespace std {
    using ::strlen;
  }

would work.  That should get code that as good as C in terms of
builtins (or if it doesn't I can easily tweak it so that it does).

If we have to punt on this particular aspect of conformance
completely, i.e., do not provide <string.h> and just make <cstring>
be:

  #include <string.h>

even that is not the end of the world.  

It is not a regression from GCC 2.95.2, and the other many wonders of
the new library will still be available to everyone.  

--
Mark Mitchell                   mark@codesourcery.com
CodeSourcery, LLC               http://www.codesourcery.com



More information about the Libstdc++ mailing list