You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@openoffice.apache.org by hd...@apache.org on 2013/12/10 20:18:49 UTC

svn commit: r1549940 - in /openoffice/trunk: ./ main/bridges/source/cpp_uno/s5abi_macosx_x86-64/except.cxx main/bridges/source/cpp_uno/s5abi_macosx_x86-64/share.hxx

Author: hdu
Date: Tue Dec 10 19:18:49 2013
New Revision: 1549940

URL: http://svn.apache.org/r1549940
Log:
#i122195# provide proper type_info for UNO exceptions on OSX 64bit

on OSX 64bit the class_type_info classes are specified
in http://refspecs.linuxbase.org/cxxabi-1.86.html#rtti but
these details are not generally available in a public header
of most development environments. So we define them locally.

Modified:
    openoffice/trunk/   (props changed)
    openoffice/trunk/main/bridges/source/cpp_uno/s5abi_macosx_x86-64/except.cxx
    openoffice/trunk/main/bridges/source/cpp_uno/s5abi_macosx_x86-64/share.hxx

Propchange: openoffice/trunk/
------------------------------------------------------------------------------
  Merged /openoffice/branches/rejuvenate01:r1534098,1549902

Modified: openoffice/trunk/main/bridges/source/cpp_uno/s5abi_macosx_x86-64/except.cxx
URL: http://svn.apache.org/viewvc/openoffice/trunk/main/bridges/source/cpp_uno/s5abi_macosx_x86-64/except.cxx?rev=1549940&r1=1549939&r2=1549940&view=diff
==============================================================================
--- openoffice/trunk/main/bridges/source/cpp_uno/s5abi_macosx_x86-64/except.cxx (original)
+++ openoffice/trunk/main/bridges/source/cpp_uno/s5abi_macosx_x86-64/except.cxx Tue Dec 10 19:18:49 2013
@@ -177,7 +177,6 @@ type_info * RTTI::getRTTI( typelib_Compo
 #if OSL_DEBUG_LEVEL > 1
                 fprintf( stderr,"generated rtti for %s\n", rttiName );
 #endif
-#if 0 // TODO: the derived type_info classes are not directly available => get them indirectly?
                 if (pTypeDescr->pBaseTypeDescription)
                 {
                     // ensure availability of base
@@ -195,9 +194,6 @@ type_info * RTTI::getRTTI( typelib_Compo
                 pair< t_rtti_map::iterator, bool > insertion(
                     m_generatedRttis.insert( t_rtti_map::value_type( unoName, rtti ) ) );
                 OSL_ENSURE( insertion.second, "### inserting new generated rtti failed?!" );
-#else
-		return NULL;
-#endif
             }
             else // taking already generated rtti
             {

Modified: openoffice/trunk/main/bridges/source/cpp_uno/s5abi_macosx_x86-64/share.hxx
URL: http://svn.apache.org/viewvc/openoffice/trunk/main/bridges/source/cpp_uno/s5abi_macosx_x86-64/share.hxx?rev=1549940&r1=1549939&r2=1549940&view=diff
==============================================================================
--- openoffice/trunk/main/bridges/source/cpp_uno/s5abi_macosx_x86-64/share.hxx (original)
+++ openoffice/trunk/main/bridges/source/cpp_uno/s5abi_macosx_x86-64/share.hxx Tue Dec 10 19:18:49 2013
@@ -85,6 +85,27 @@ extern "C" __cxa_eh_globals *__cxa_get_g
 
 // -----
 
+// on OSX 64bit the class_type_info classes are specified
+// in http://refspecs.linuxbase.org/cxxabi-1.86.html#rtti but
+// these details are not generally available in a public header
+// of most development environments. So we define them here.
+class __class_type_info : public std::type_info
+{
+public:
+        explicit __class_type_info( const char* pRttiName)
+        : std::type_info( pRttiName)
+        {}
+};
+
+class __si_class_type_info : public __class_type_info
+{
+        const __class_type_info* mpBaseType;
+public:
+        explicit __si_class_type_info( const char* pRttiName, __class_type_info* pBaseType)
+        : __class_type_info( pRttiName), mpBaseType( pBaseType)
+        {}
+};
+
 //==================================================================================================
 void raiseException(
     uno_Any * pUnoExc, uno_Mapping * pUno2Cpp );