summaryrefslogtreecommitdiff
path: root/bridges/source/cpp_uno/gcc3_linux_m68k/cpp2uno.cxx
diff options
context:
space:
mode:
Diffstat (limited to 'bridges/source/cpp_uno/gcc3_linux_m68k/cpp2uno.cxx')
-rw-r--r--bridges/source/cpp_uno/gcc3_linux_m68k/cpp2uno.cxx14
1 files changed, 6 insertions, 8 deletions
diff --git a/bridges/source/cpp_uno/gcc3_linux_m68k/cpp2uno.cxx b/bridges/source/cpp_uno/gcc3_linux_m68k/cpp2uno.cxx
index 403ec52be813..f798735dbfa1 100644
--- a/bridges/source/cpp_uno/gcc3_linux_m68k/cpp2uno.cxx
+++ b/bridges/source/cpp_uno/gcc3_linux_m68k/cpp2uno.cxx
@@ -92,7 +92,7 @@ namespace
pCppStack += sizeof( void* );
// stack space
- OSL_ENSURE( sizeof(void *) == sizeof(sal_Int32),
+ static_assert( sizeof(void *) == sizeof(sal_Int32),
"### unexpected size!" );
// parameters
void ** pUnoArgs = (void **)alloca( 4 * sizeof(void *) * nParams );
@@ -272,7 +272,7 @@ namespace
fprintf(stderr, "and %x %x\n", pCallStack, pRegisterReturn);
fprintf(stderr, "and %x %x\n", pCallStack[0], pCallStack[1]);
#endif
- OSL_ENSURE( sizeof(sal_Int32)==sizeof(void *), "### unexpected!" );
+ static_assert( sizeof(sal_Int32)==sizeof(void *), "### unexpected!" );
void *pThis = pCallStack[0];
@@ -299,12 +299,10 @@ namespace
}
// determine called method
- OSL_ENSURE( nFunctionIndex < pTypeDescr->nMapFunctionIndexToMemberIndex,
- "### illegal vtable index!" );
+ assert(nFunctionIndex < pTypeDescr->nMapFunctionIndexToMemberIndex);
sal_Int32 nMemberPos =
pTypeDescr->pMapFunctionIndexToMemberIndex[nFunctionIndex];
- OSL_ENSURE( nMemberPos < pTypeDescr->nAllMembers,
- "### illegal member index!" );
+ assert(nMemberPos < pTypeDescr->nAllMembers);
TypeDescription aMemberDescr( pTypeDescr->ppAllMembers[nMemberPos] );
@@ -480,7 +478,7 @@ unsigned char * bridges::cpp_uno::shared::VtableFactory::addLocalFunctions(
{
typelib_TypeDescription * member = 0;
TYPELIB_DANGER_GET(&member, type->ppMembers[i]);
- OSL_ASSERT(member != 0);
+ assert(member != 0);
switch (member->eTypeClass)
{
case typelib_TypeClass_INTERFACE_ATTRIBUTE:
@@ -508,7 +506,7 @@ unsigned char * bridges::cpp_uno::shared::VtableFactory::addLocalFunctions(
break;
}
default:
- OSL_ASSERT(false);
+ assert(false);
break;
}
TYPELIB_DANGER_RELEASE(member);