diff options
author | DJ Delorie <dj@redhat.com> | 2011-10-22 01:35:29 +0000 |
---|---|---|
committer | DJ Delorie <dj@redhat.com> | 2011-10-22 01:35:29 +0000 |
commit | bdea9e5fe8cb19d89015d8a6543ecab4b9e76a01 (patch) | |
tree | ab4961af3d0a707c2e4243d151538575f4753bb2 /include/ansidecl.h | |
parent | 22e671336e8db5fe4f026d1c0c8eb98b4e7d728f (diff) | |
download | cygnal-bdea9e5fe8cb19d89015d8a6543ecab4b9e76a01.tar.gz cygnal-bdea9e5fe8cb19d89015d8a6543ecab4b9e76a01.tar.bz2 cygnal-bdea9e5fe8cb19d89015d8a6543ecab4b9e76a01.zip |
* obstack.h [!GNUC] (obstack_free): Avoid cast to int.
* ansidecl.h (ENUM_BITFIELD): Always use enum in C++
Diffstat (limited to 'include/ansidecl.h')
-rw-r--r-- | include/ansidecl.h | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/include/ansidecl.h b/include/ansidecl.h index c39ce2f5d..23d85bf0e 100644 --- a/include/ansidecl.h +++ b/include/ansidecl.h @@ -416,10 +416,12 @@ So instead we use the macro below and test it against specific values. */ #define EXPORTED_CONST const #endif -/* Be conservative and only use enum bitfields with GCC. +/* Be conservative and only use enum bitfields with C++ or GCC. FIXME: provide a complete autoconf test for buggy enum bitfields. */ -#if (GCC_VERSION > 2000) +#ifdef __cplusplus +#define ENUM_BITFIELD(TYPE) enum TYPE +#elif (GCC_VERSION > 2000) #define ENUM_BITFIELD(TYPE) __extension__ enum TYPE #else #define ENUM_BITFIELD(TYPE) unsigned int |