[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: AC_PROG_CC_C99
From: |
Paul Eggert |
Subject: |
Re: AC_PROG_CC_C99 |
Date: |
Tue, 04 Jan 2005 15:59:44 -0800 |
User-agent: |
Gnus/5.1006 (Gnus v5.10.6) Emacs/21.3 (gnu/linux) |
Noah Misch <address@hidden> writes:
> Do there exist compilers that accept neither C89 nor C99 by default, but that
> can accept both given options?
It depends on what you mean by "accept". GCC doesn't accept either
language by default, as it doesn't do trigraph processing; but nobody
uses trigraphs in practice, so this is not worth worrying about.
It's possible to write valid C89 code that will break if you compile
it with a C99 compiler (e.g., "x = y//**/z;"), but it's rare enough
that it's not worth worrying about.
> will it work for AC_PROG_CC_C89 (via AC_PROG_CC) to add the
> C89-tolerance option, and for AC_PROG_CC_99 to then try to add the
> C99-tolerance option in addition?
Good question. We'd rather have it do C99 from day one in that case,
I suppose. Roger?
> I have been thinking, would it be better to create a new macro name, say
> `AC_PROG_CC_ISO'?
That wouldn't be a good name, as both C89 and C99 are ISO standards.
> Certainly nobody depends on AC_PROG_CC_STDC making the compiler
> accept C99, so perhaps we only stand to surprise people by giving it
> that meaning?
Well, it was marked as obsolete. :-)
To be honest I don't think it'll cause that many problems, as C99 is
mostly upwards compatible with C89. I suspect that most compilers
that can do either, will be in C99ish mode by default.
- Re: AC_PROG_CC_C99, Roger Leigh, 2005/01/01
- Re: AC_PROG_CC_C99, Paul Eggert, 2005/01/03
- Re: AC_PROG_CC_C99, Noah Misch, 2005/01/04
- Re: AC_PROG_CC_C99,
Paul Eggert <=
- Re: AC_PROG_CC_C99, Noah Misch, 2005/01/04
- Re: AC_PROG_CC_C99, Roger Leigh, 2005/01/05
- Re: AC_PROG_CC_C99, Noah Misch, 2005/01/09
- Re: AC_PROG_CC_C99, Roger Leigh, 2005/01/12
- Re: AC_PROG_CC_C99, Noah Misch, 2005/01/13
- Re: AC_PROG_CC_C99, Roger Leigh, 2005/01/05