diff options
author | Stephan Bergmann <sbergman@redhat.com> | 2012-04-04 13:02:44 +0200 |
---|---|---|
committer | Stephan Bergmann <sbergman@redhat.com> | 2012-04-04 13:02:44 +0200 |
commit | b0515ea5fa6c29faebed616ae3e0213c72d24904 (patch) | |
tree | 3c83788fad2c1d1a6a806e6f2e70b0b9ceebe407 /bridges/source/cpp_uno/gcc3_linux_intel/share.hxx | |
parent | 13191ad7cd25871c08066817b6cc55b0d7ea419e (diff) |
Adapt cpp_uno/gcc3_linux_intel to GCC 4.7
...the same way cpp_uno/gcc3_linux_x86-64 was already adapted.
Diffstat (limited to 'bridges/source/cpp_uno/gcc3_linux_intel/share.hxx')
-rw-r--r-- | bridges/source/cpp_uno/gcc3_linux_intel/share.hxx | 27 |
1 files changed, 19 insertions, 8 deletions
diff --git a/bridges/source/cpp_uno/gcc3_linux_intel/share.hxx b/bridges/source/cpp_uno/gcc3_linux_intel/share.hxx index 8a3e136bfb7b..2eff5576362f 100644 --- a/bridges/source/cpp_uno/gcc3_linux_intel/share.hxx +++ b/bridges/source/cpp_uno/gcc3_linux_intel/share.hxx @@ -35,8 +35,6 @@ namespace CPPU_CURRENT_NAMESPACE { -void dummy_can_throw_anything( char const * ); - // ----- following decl from libstdc++-v3/libsupc++/unwind-cxx.h and unwind.h struct _Unwind_Exception @@ -68,17 +66,30 @@ struct __cxa_exception _Unwind_Exception unwindHeader; }; -extern "C" void *__cxa_allocate_exception( - std::size_t thrown_size ) throw(); -extern "C" void __cxa_throw ( - void *thrown_exception, std::type_info *tinfo, void (*dest) (void *) ) __attribute__((noreturn)); - struct __cxa_eh_globals { __cxa_exception *caughtExceptions; unsigned int uncaughtExceptions; }; -extern "C" __cxa_eh_globals *__cxa_get_globals () throw(); + +} + +extern "C" CPPU_CURRENT_NAMESPACE::__cxa_eh_globals *__cxa_get_globals () throw(); + +namespace CPPU_CURRENT_NAMESPACE +{ + +// The following are in cxxabi.h since GCC 4.7 (they are wrapped in +// CPPU_CURRENT_NAMESPACE here as different GCC versions have slightly different +// declarations for them, e.g., with or without throw() specification, so would +// complain about redeclarations of these somewhat implicitly declared +// functions): +#if __GNUC__ == 4 && __GNUC_MINOR__ <= 6 +extern "C" void *__cxa_allocate_exception( + std::size_t thrown_size ) throw(); +extern "C" void __cxa_throw ( + void *thrown_exception, void *tinfo, void (*dest) (void *) ) __attribute__((noreturn)); +#endif // ----- |