summaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorjkratoch <jkratoch@138bc75d-0d04-0410-961f-82ee72b054a4>2011-04-25 18:05:37 +0000
committerjkratoch <jkratoch@138bc75d-0d04-0410-961f-82ee72b054a4>2011-04-25 18:05:37 +0000
commitcdd0bb4bde4f6885045e65860de0320ccf6b23f6 (patch)
tree1aa599e5471722eac22c8d3e11ec5a6fc3e2af51 /include
parenta59bc27b396d46757e6f4ceae4d1bd1e438d610c (diff)
downloadgcc-cdd0bb4bde4f6885045e65860de0320ccf6b23f6.tar.gz
include/
* ansidecl.h (ENUM_BITFIELD): New, from gcc/system.h. contrib/ * paranoia.cc (ENUM_BITFIELD): Remove. gcc/ * system.h (ENUM_BITFIELD): Remove. libcpp/ * system.h (ENUM_BITFIELD): Remove. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@172933 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'include')
-rw-r--r--include/ChangeLog4
-rw-r--r--include/ansidecl.h9
2 files changed, 13 insertions, 0 deletions
diff --git a/include/ChangeLog b/include/ChangeLog
index 4d05ba0c4bf..fcabfb8384c 100644
--- a/include/ChangeLog
+++ b/include/ChangeLog
@@ -1,3 +1,7 @@
+2011-04-25 Jan Kratochvil <jan.kratochvil@redhat.com>
+
+ * ansidecl.h (ENUM_BITFIELD): New, from gcc/system.h.
+
2011-03-31 Tristan Gingold <gingold@adacore.com>
* dwarf2.h (dwarf_line_number_hp_sfc_ops): New enum.
diff --git a/include/ansidecl.h b/include/ansidecl.h
index 8b76647426b..c39ce2f5d70 100644
--- a/include/ansidecl.h
+++ b/include/ansidecl.h
@@ -416,6 +416,15 @@ 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.
+ FIXME: provide a complete autoconf test for buggy enum bitfields. */
+
+#if (GCC_VERSION > 2000)
+#define ENUM_BITFIELD(TYPE) __extension__ enum TYPE
+#else
+#define ENUM_BITFIELD(TYPE) unsigned int
+#endif
+
#ifdef __cplusplus
}
#endif