On Tue, 28 Jun 2005 17:05:17 +0000, Walter Roberson wrote:
....
I'm not a sharp enough language-lawyer to resolve this question:
When the C89 standard admits of something being a "common extension"
then is a compiler "non-compliant" for implementing that extension
(e.g., due to potential clashes with use of those words in code)?
The C standard doesn't recognise compilers as such, it talks about
"implementations". An implementation includes everything that can affect
the behaviour of a program, the compiler, libraries, linker, runtime
environment etc., and in particular the configuration data for these. So
by changing the command line options when running a compiler you are
creating a different implementation. A compiler (in conjunction with
everything else) may provide a comforming implementation wih one set of
command line options but not with another, which is perfectly reasonable.
If so, would it be sufficient for the compiler to provide a means to
turn off recognizition of the extension?
The concept of a "compliant compiler" isn't a standard one. It probably
means a compiler that can be part of a conforming implementation when
given appropriate options, but it is an informal concept.
Lawrence