aboutsummaryrefslogtreecommitdiff
path: root/include/ansidecl.h
diff options
context:
space:
mode:
authorAlan Modra <amodra@gmail.com>2022-05-31 16:59:12 +0930
committerAlan Modra <amodra@gmail.com>2022-05-31 21:14:00 +0930
commit2918df9368abdedffe2e2be1c93c760d85d545ab (patch)
tree77a44e7030414a0768a608547f6235bb5642cac2 /include/ansidecl.h
parent42745ac5821471e8b953d24730c82c3cefa72d67 (diff)
downloadgdb-2918df9368abdedffe2e2be1c93c760d85d545ab.zip
gdb-2918df9368abdedffe2e2be1c93c760d85d545ab.tar.gz
gdb-2918df9368abdedffe2e2be1c93c760d85d545ab.tar.bz2
Import libiberty from gcc
PR 29200 include/ * ansidecl.h, * demangle.h: Import from gcc. libiberty/ * cp-demangle.c, * testsuite/demangle-expected: Import from gcc.
Diffstat (limited to 'include/ansidecl.h')
-rw-r--r--include/ansidecl.h41
1 files changed, 0 insertions, 41 deletions
diff --git a/include/ansidecl.h b/include/ansidecl.h
index 46fe3ff..056a03e 100644
--- a/include/ansidecl.h
+++ b/include/ansidecl.h
@@ -321,47 +321,6 @@ So instead we use the macro below and test it against specific values. */
#define CONSTEXPR
#endif
-/* C++11 adds the ability to add "override" after an implementation of a
- virtual function in a subclass, to:
- (A) document that this is an override of a virtual function
- (B) allow the compiler to issue a warning if it isn't (e.g. a mismatch
- of the type signature).
-
- Similarly, it allows us to add a "final" to indicate that no subclass
- may subsequently override the vfunc.
-
- Provide OVERRIDE and FINAL as macros, allowing us to get these benefits
- when compiling with C++11 support, but without requiring C++11.
-
- For gcc, use "-std=c++11" to enable C++11 support; gcc 6 onwards enables
- this by default (actually GNU++14). */
-
-#if defined __cplusplus
-# if __cplusplus >= 201103
- /* C++11 claims to be available: use it. Final/override were only
- implemented in 4.7, though. */
-# if GCC_VERSION < 4007
-# define OVERRIDE
-# define FINAL
-# else
-# define OVERRIDE override
-# define FINAL final
-# endif
-# elif GCC_VERSION >= 4007
- /* G++ 4.7 supports __final in C++98. */
-# define OVERRIDE
-# define FINAL __final
-# else
- /* No C++11 support; leave the macros empty. */
-# define OVERRIDE
-# define FINAL
-# endif
-#else
- /* No C++11 support; leave the macros empty. */
-# define OVERRIDE
-# define FINAL
-#endif
-
/* A macro to disable the copy constructor and assignment operator.
When building with C++11 and above, the methods are explicitly
deleted, causing a compile-time error if something tries to copy.