[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]


From: Noah Misch
Subject: Re: AC_PROG_CC_C99
Date: Tue, 4 Jan 2005 13:33:30 -0800
User-agent: Mutt/1.5.6i

On Sun, Jan 02, 2005 at 11:35:42PM -0800, Paul Eggert wrote:

> +** AC_PROG_CC_C89, AC_PROG_CC_C99
> +  New macros for ISO C99 support.  AC_PROG_CC_C89 and AC_PROG_CC_C99
> +  check for ANSI C89 and ISO C99 support respectively.

Do there exist compilers that accept neither C89 nor C99 by default, but that
can accept both given options?  If so, 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?

> +
> +  Has been unobsoleted, and will check if the compiler supports ISO
> +  C99, falling back to ANSI C89 if not.  ac_cv_prog_cc_stdc is
> +  retained for backwards compatibility, assuming the value of
> +  ac_cv_prog_cc_c99 or ac_cv_prog_cc_c89 (whichever is valid, in
> +  that order).

I have been thinking, would it be better to create a new macro name, say
`AC_PROG_CC_ISO'?  I suspect most developers used `AC_PROG_CC_STDC' because
their code used prototypes and other C89 innovations unconditionally, not
because they always wanted the compiler to respect the latest standard.
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?

reply via email to

[Prev in Thread] Current Thread [Next in Thread]