diff options
author | Matthieu Herrb <matthieu.herrb@laas.fr> | 2011-04-20 22:57:05 +0200 |
---|---|---|
committer | Matthieu Herrb <matthieu.herrb@laas.fr> | 2011-04-21 07:20:38 +0200 |
commit | 19c12c60c22d5a23039bc90845a6ecacdd64f2db (patch) | |
tree | 0d49ad07b3ca3781bbf23658ce92ca8ca5223411 | |
parent | da46c2d0e11c1709b7dd6b2c79253ce8751c81bb (diff) |
Fix __STDC_VERSION__ tests.
the existing test:
defined(__STDC__) && (__STDC_VERSION__ - 0 >= 199901L) causes an
warning when building X stuff with gcc -Wundef. Other tests for
__STDC_VERSION__ in the X sources all use
defined(__STDC_VERSION__) && (__STDC_VERSION__ -0 >= 199901L)
Signed-off-by: Matthieu Herrb <matthieu.herrb@laas.fr>
Reviewed-by: Matt Turner <mattst88@gmail.com>
Reviewed-by: Alan Coopersmith <alan.coopersmith@oracle.com>
-rw-r--r-- | Xfuncproto.h.in | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/Xfuncproto.h.in b/Xfuncproto.h.in index 97e925b..2b8a226 100644 --- a/Xfuncproto.h.in +++ b/Xfuncproto.h.in @@ -124,7 +124,7 @@ in this Software without prior written authorization from The Open Group. /* C99 keyword "inline" or equivalent extensions in pre-C99 compilers */ #if defined(inline) /* assume autoconf set it correctly */ || \ - (defined(__STDC__) && (__STDC_VERSION__ - 0 >= 199901L)) /* C99 */ || \ + (defined(__STDC_VERSION__) && (__STDC_VERSION__ - 0 >= 199901L)) /* C99 */ || \ (defined(__SUNPRO_C) && (__SUNPRO_C >= 0x550)) # define _X_INLINE inline #elif defined(__GNUC__) && !defined(__STRICT_ANSI__) /* gcc w/C89+extensions */ @@ -136,7 +136,7 @@ in this Software without prior written authorization from The Open Group. /* C99 keyword "restrict" or equivalent extensions in pre-C99 compilers */ #ifndef _X_RESTRICT_KYWD # if defined(restrict) /* assume autoconf set it correctly */ || \ - (defined(__STDC__) && (__STDC_VERSION__ - 0 >= 199901L)) /* C99 */ + (defined(__STDC_VERSION__) && (__STDC_VERSION__ - 0 >= 199901L)) /* C99 */ # define _X_RESTRICT_KYWD restrict # elif defined(__GNUC__) && !defined(__STRICT_ANSI__) /* gcc w/C89+extensions */ # define _X_RESTRICT_KYWD __restrict__ |