This is the mail archive of the
binutils-cvs@sourceware.org
mailing list for the binutils project.
[binutils-gdb] Sync ansidecl.h with GCC
- From: H.J.Lu <hjl at sourceware dot org>
- To: bfd-cvs at sourceware dot org
- Date: 12 Aug 2015 12:03:00 -0000
- Subject: [binutils-gdb] Sync ansidecl.h with GCC
https://sourceware.org/git/gitweb.cgi?p=binutils-gdb.git;h=dd419f3aac048176e4e760dc8f29d3429c4f07ce
commit dd419f3aac048176e4e760dc8f29d3429c4f07ce
Author: H.J. Lu <hjl.tools@gmail.com>
Date: Wed Aug 12 05:02:21 2015 -0700
Sync ansidecl.h with GCC
Sync with GCC
2015-08-11 Trevor Saunders <tbsaunde+gcc@tbsaunde.org>
* ansidecl.h (GCC_FINAL): New macro.
Diff:
---
include/ChangeLog | 7 +++++++
include/ansidecl.h | 9 +++++++++
2 files changed, 16 insertions(+)
diff --git a/include/ChangeLog b/include/ChangeLog
index 8a45307..df9e2e2 100644
--- a/include/ChangeLog
+++ b/include/ChangeLog
@@ -1,3 +1,10 @@
+2015-08-12 H.J. Lu <hongjiu.lu@intel.com>
+
+ Sync with GCC
+ 2015-08-11 Trevor Saunders <tbsaunde+gcc@tbsaunde.org>
+
+ * ansidecl.h (GCC_FINAL): New macro.
+
2015-07-16 Jiong Wang <jiong.wang@arm.com>
* elf/aarch64.h (R_AARCH64_P32_TLSLD_ADR_PREL21): New enumeration.
diff --git a/include/ansidecl.h b/include/ansidecl.h
index 224627d..6e4bfc2 100644
--- a/include/ansidecl.h
+++ b/include/ansidecl.h
@@ -313,6 +313,15 @@ So instead we use the macro below and test it against specific values. */
#define ENUM_BITFIELD(TYPE) unsigned int
#endif
+ /* This is used to mark a class or virtual function as final. */
+#if __cplusplus >= 201103L
+#define GCC_FINAL final
+#elif GCC_VERSION >= 4007
+#define GCC_FINAL __final
+#else
+#define GCC_FINAL
+#endif
+
#ifdef __cplusplus
}
#endif