[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: c99
From: |
vishnu |
Subject: |
Re: c99 |
Date: |
Sat, 13 Oct 2001 10:22:31 -0700 |
User-agent: |
Mutt/1.3.20i |
On Sat, Oct 13, 2001 at 06:46:35PM +0200, Guido Draheim wrote:
> address@hidden wrote:
> > i'm using:
> >
> > for (gint xx=0; xx < 3; xx++) { .. }
> >
> > and i generally mix variable declarations and statements as i
> > please instead of putting all the declarations near the open brace.
> >
> > In terms of an autoconf probe, what do you suggest?
>
> ouch, that's a autoconf-test that has not been written so far, even
> more for this special case there were two interpretations (with xx
> being seen as ifdeclared outside of for() or the symbols is only valid
> within the for()) - of course it could be easily written (and would
> go the macro-archive then) - somebody around here who has an example
> ready?
The following test seems to work. It might be nice to guess the
-std=gnu99 option if CC = gcc. Can you help me improve the style?
Thanks ..
AC_MSG_CHECKING([whether $CC accepts C99 declarations])
AC_TRY_COMPILE([],[
int x=0; x+=1; int y=0;
for (int z=0; z < 2; z++);
],[
AC_MSG_RESULT(yes)
],
[
AC_MSG_ERROR([
*** This package requires a C99 compiler.])
])
--
Victory to the Divine Mother!!
http://sahajayoga.org
- c99, vishnu, 2001/10/12
- Re: c99, Guido Draheim, 2001/10/13
- Re: c99, vishnu, 2001/10/13
- Re: c99, Guido Draheim, 2001/10/13
- Re: c99,
vishnu <=
- Re: c99, Paul Eggert, 2001/10/13
- Re: c99, vishnu, 2001/10/13
- Re: c99, Guido Draheim, 2001/10/13
- Re: c99, vishnu, 2001/10/13
- Re: c99, Guido Draheim, 2001/10/13
- Re: c99, vishnu, 2001/10/14
- Re: c99, vishnu, 2001/10/14
- Re: c99, Guido Draheim, 2001/10/14
- Re: c99, vishnu, 2001/10/18
- Subscribe/unsubscribe, Sang Nguyen Minh, 2001/10/18