ISO C++ and C99 features

Nathan Sidwell
Tue Jun 13 03:45:00 GMT 2000

[This stuff about long long, -ansi etc]

I think it'll get worse, in that users will ask for more c99
features to be available in C++. Note the number of bug reports
we get about rejecting some C inside an extern "C" scope. It would
be good if we could provide a mode where such an amalgamation is
available (without other extensions). With my user hat on, I
already use long long (and so -Wno-long-long), and use c99 vararg
macros (I live with the warning). And, as a user, I'd be very
surprised/annoyed if the next rev of C++ did not include most of C99.
I also like portable programs (so those features are autoconf'd), and
I like to be told when I'm straying from the standard (rather than
randomly wander into extension land).

Now, as a picky compiler head, I like sticking to the standard.
But standards are mutable things, we already track the DR's and
their likely resolution. I do think we should have a mode
which implements the current standard as she is wrote, which
we do have with -ansi -pedantic. Tracking the DRs is fine for that
mode, as they are committee documents, so reflect the consensus
across many compiler vendors and users.

We have a more permissive compiler with -fpermissive (which is the
right way to do it - reject by default so you know there's a problem).

Standards are set, in part, from existing practice -- so we'd better
create some! I'd like a more futuristic compiler with -fprescient
or -fxtal-ball. I suppose we could say all gnu extensions are our
proposal for the next standard, in which case I'm out of luck.

Pragmatically, I suggest we punt on this til after 3.0, and in the
meantime think about whether we call it -xc++2k or -xc++ -ffuturerama.


Dr Nathan Sidwell   ::   ::   CodeSourcery LLC
         'But that's a lie.' - 'Yes it is. What's your point?' : :

More information about the Gcc mailing list