summaryrefslogtreecommitdiff
path: root/cppu/source
diff options
context:
space:
mode:
authorStephan Bergmann <sbergman@redhat.com>2014-02-15 17:39:35 +0100
committerStephan Bergmann <sbergman@redhat.com>2014-02-17 17:55:18 +0100
commit34a44156b3983849749d82b90d82b84aeb538aae (patch)
tree393815dd01ca56cadb7b8f63f477b553e98c06f6 /cppu/source
parent5dd4a0690124c0d3fc1835a59e0fca2d12773afe (diff)
cppu: sal_Bool -> bool
Change-Id: I1288f1f6f38d1475b4eb5272509e479bd9f2552d
Diffstat (limited to 'cppu/source')
-rw-r--r--cppu/source/threadpool/current.cxx8
-rw-r--r--cppu/source/threadpool/current.hxx2
-rw-r--r--cppu/source/threadpool/jobqueue.cxx14
-rw-r--r--cppu/source/threadpool/jobqueue.hxx10
-rw-r--r--cppu/source/threadpool/thread.cxx6
-rw-r--r--cppu/source/threadpool/thread.hxx6
-rw-r--r--cppu/source/threadpool/threadident.cxx4
-rw-r--r--cppu/source/threadpool/threadpool.cxx32
-rw-r--r--cppu/source/threadpool/threadpool.hxx8
-rw-r--r--cppu/source/typelib/typelib.cxx12
-rw-r--r--cppu/source/uno/assign.hxx146
-rw-r--r--cppu/source/uno/data.cxx6
-rw-r--r--cppu/source/uno/eq.hxx104
-rw-r--r--cppu/source/uno/lbmap.cxx4
-rw-r--r--cppu/source/uno/prim.hxx2
15 files changed, 182 insertions, 182 deletions
diff --git a/cppu/source/threadpool/current.cxx b/cppu/source/threadpool/current.cxx
index 340ef211a485..0b8f5ab70b04 100644
--- a/cppu/source/threadpool/current.cxx
+++ b/cppu/source/threadpool/current.cxx
@@ -98,7 +98,7 @@ static typelib_InterfaceTypeDescription * get_type_XCurrentContext()
//==================================================================================================
class ThreadKey
{
- sal_Bool _bInit;
+ bool _bInit;
oslThreadKey _hThreadKey;
oslThreadKeyCallbackFunction _pCallback;
@@ -110,7 +110,7 @@ public:
};
//__________________________________________________________________________________________________
inline ThreadKey::ThreadKey( oslThreadKeyCallbackFunction pCallback ) SAL_THROW(())
- : _bInit( sal_False )
+ : _bInit( false )
, _pCallback( pCallback )
{
}
@@ -131,7 +131,7 @@ inline oslThreadKey ThreadKey::getThreadKey() SAL_THROW(())
if (! _bInit)
{
_hThreadKey = ::osl_createThreadKey( _pCallback );
- _bInit = sal_True;
+ _bInit = true;
}
}
return _hThreadKey;
@@ -170,7 +170,7 @@ IdContainer * getIdContainer() SAL_THROW(())
pId = new IdContainer();
pId->pCurrentContext = 0;
pId->pCurrentContextEnv = 0;
- pId->bInit = sal_False;
+ pId->bInit = false;
::osl_setThreadKeyData( aKey, pId );
}
return pId;
diff --git a/cppu/source/threadpool/current.hxx b/cppu/source/threadpool/current.hxx
index 127f2024a911..f425fd3ad0aa 100644
--- a/cppu/source/threadpool/current.hxx
+++ b/cppu/source/threadpool/current.hxx
@@ -33,7 +33,7 @@ struct IdContainer
void * pCurrentContext;
uno_ExtEnvironment * pCurrentContextEnv;
//
- sal_Bool bInit;
+ bool bInit;
sal_Sequence * pLocalThreadId;
sal_Int32 nRefCountOfCurrentId;
sal_Sequence * pCurrentId;
diff --git a/cppu/source/threadpool/jobqueue.cxx b/cppu/source/threadpool/jobqueue.cxx
index 70d05acd6ad6..ec7b932d7b11 100644
--- a/cppu/source/threadpool/jobqueue.cxx
+++ b/cppu/source/threadpool/jobqueue.cxx
@@ -28,7 +28,7 @@ namespace cppu_threadpool {
JobQueue::JobQueue() :
m_nToDo( 0 ),
- m_bSuspended( sal_False ),
+ m_bSuspended( false ),
m_cndWait( osl_createCondition() )
{
osl_resetCondition( m_cndWait );
@@ -53,7 +53,7 @@ namespace cppu_threadpool {
m_nToDo ++;
}
- void *JobQueue::enter( sal_Int64 nDisposeId , sal_Bool bReturnWhenNoJob )
+ void *JobQueue::enter( sal_Int64 nDisposeId , bool bReturnWhenNoJob )
{
void *pReturn = 0;
{
@@ -157,32 +157,32 @@ namespace cppu_threadpool {
void JobQueue::suspend()
{
MutexGuard guard( m_mutex );
- m_bSuspended = sal_True;
+ m_bSuspended = true;
}
void JobQueue::resume()
{
MutexGuard guard( m_mutex );
- m_bSuspended = sal_False;
+ m_bSuspended = false;
if( ! m_lstJob.empty() )
{
osl_setCondition( m_cndWait );
}
}
- sal_Bool JobQueue::isEmpty() const
+ bool JobQueue::isEmpty() const
{
MutexGuard guard( m_mutex );
return m_lstJob.empty();
}
- sal_Bool JobQueue::isCallstackEmpty() const
+ bool JobQueue::isCallstackEmpty() const
{
MutexGuard guard( m_mutex );
return m_lstCallstack.empty();
}
- sal_Bool JobQueue::isBusy() const
+ bool JobQueue::isBusy() const
{
MutexGuard guard( m_mutex );
return m_nToDo > 0;
diff --git a/cppu/source/threadpool/jobqueue.hxx b/cppu/source/threadpool/jobqueue.hxx
index baaa3d21a224..66b1a675edef 100644
--- a/cppu/source/threadpool/jobqueue.hxx
+++ b/cppu/source/threadpool/jobqueue.hxx
@@ -53,22 +53,22 @@ namespace cppu_threadpool
void add( void *pThreadSpecificData, RequestFun * doRequest );
- void *enter( sal_Int64 nDisposeId , sal_Bool bReturnWhenNoJob = sal_False );
+ void *enter( sal_Int64 nDisposeId , bool bReturnWhenNoJob = false );
void dispose( sal_Int64 nDisposeId );
void suspend();
void resume();
- sal_Bool isEmpty() const;
- sal_Bool isCallstackEmpty() const;
- sal_Bool isBusy() const;
+ bool isEmpty() const;
+ bool isCallstackEmpty() const;
+ bool isBusy() const;
private:
mutable ::osl::Mutex m_mutex;
JobList m_lstJob;
CallStackList m_lstCallstack;
sal_Int32 m_nToDo;
- sal_Bool m_bSuspended;
+ bool m_bSuspended;
oslCondition m_cndWait;
DisposedCallerAdminHolder m_DisposedCallerAdmin;
};
diff --git a/cppu/source/threadpool/thread.cxx b/cppu/source/threadpool/thread.cxx
index 85076b00157b..e8a64c685390 100644
--- a/cppu/source/threadpool/thread.cxx
+++ b/cppu/source/threadpool/thread.cxx
@@ -103,7 +103,7 @@ namespace cppu_threadpool {
ORequestThread::ORequestThread( ThreadPoolHolder const &aThreadPool,
JobQueue *pQueue,
const ByteSequence &aThreadId,
- sal_Bool bAsynchron )
+ bool bAsynchron )
: m_aThreadPool( aThreadPool )
, m_pQueue( pQueue )
, m_aThreadId( aThreadId )
@@ -114,7 +114,7 @@ namespace cppu_threadpool {
void ORequestThread::setTask( JobQueue *pQueue,
const ByteSequence &aThreadId,
- sal_Bool bAsynchron )
+ bool bAsynchron )
{
m_pQueue = pQueue;
m_aThreadId = aThreadId;
@@ -169,7 +169,7 @@ namespace cppu_threadpool {
m_pQueue->enter(
sal::static_int_cast< sal_Int64 >(
reinterpret_cast< sal_IntPtr >(this)),
- sal_True );
+ true );
if( m_pQueue->isEmpty() )
{
diff --git a/cppu/source/threadpool/thread.hxx b/cppu/source/threadpool/thread.hxx
index dadd2b1f5843..49785bc18ded 100644
--- a/cppu/source/threadpool/thread.hxx
+++ b/cppu/source/threadpool/thread.hxx
@@ -41,10 +41,10 @@ namespace cppu_threadpool {
ORequestThread( ThreadPoolHolder const &aThreadPool,
JobQueue * ,
const ::rtl::ByteSequence &aThreadId,
- sal_Bool bAsynchron );
+ bool bAsynchron );
virtual ~ORequestThread();
- void setTask( JobQueue * , const ::rtl::ByteSequence & aThreadId , sal_Bool bAsynchron );
+ void setTask( JobQueue * , const ::rtl::ByteSequence & aThreadId , bool bAsynchron );
void launch();
@@ -61,7 +61,7 @@ namespace cppu_threadpool {
ThreadPoolHolder m_aThreadPool;
JobQueue *m_pQueue;
::rtl::ByteSequence m_aThreadId;
- sal_Bool m_bAsynchron;
+ bool m_bAsynchron;
};
} // end cppu_threadpool
diff --git a/cppu/source/threadpool/threadident.cxx b/cppu/source/threadpool/threadident.cxx
index 82c43d5dafc6..932793137008 100644
--- a/cppu/source/threadpool/threadident.cxx
+++ b/cppu/source/threadpool/threadident.cxx
@@ -68,7 +68,7 @@ uno_getIdOfCurrentThread( sal_Sequence **ppThreadId )
p->nRefCountOfCurrentId = 1;
rtl_byte_sequence_acquire( p->pLocalThreadId );
rtl_byte_sequence_acquire( p->pCurrentId );
- p->bInit = sal_True;
+ p->bInit = true;
}
else
{
@@ -108,7 +108,7 @@ extern "C" sal_Bool SAL_CALL uno_bindIdToCurrentThread( sal_Sequence *pThreadId
p->nRefCountOfCurrentId = 1;
p->pCurrentId = pThreadId;
rtl_byte_sequence_acquire( p->pCurrentId );
- p->bInit = sal_True;
+ p->bInit = true;
}
else
{
diff --git a/cppu/source/threadpool/threadpool.cxx b/cppu/source/threadpool/threadpool.cxx
index d7562191afed..493ab25f6abd 100644
--- a/cppu/source/threadpool/threadpool.cxx
+++ b/cppu/source/threadpool/threadpool.cxx
@@ -82,7 +82,7 @@ namespace cppu_threadpool
}
}
- sal_Bool DisposedCallerAdmin::isDisposed( sal_Int64 nDisposeId )
+ bool DisposedCallerAdmin::isDisposed( sal_Int64 nDisposeId )
{
MutexGuard guard( m_mutex );
for( DisposedCallerList::iterator ii = m_lst.begin() ;
@@ -91,10 +91,10 @@ namespace cppu_threadpool
{
if( (*ii) == nDisposeId )
{
- return sal_True;
+ return true;
}
}
- return sal_False;
+ return false;
}
@@ -191,9 +191,9 @@ namespace cppu_threadpool
void ThreadPool::createThread( JobQueue *pQueue ,
const ByteSequence &aThreadId,
- sal_Bool bAsynchron )
+ bool bAsynchron )
{
- sal_Bool bCreate = sal_True;
+ bool bCreate = true;
{
// Can a thread be reused ?
MutexGuard guard( m_mutexWaitingThreadList );
@@ -209,7 +209,7 @@ namespace cppu_threadpool
// let the thread go
osl_setCondition( pWaitingThread->condition );
- bCreate = sal_False;
+ bCreate = false;
}
}
@@ -221,7 +221,7 @@ namespace cppu_threadpool
}
}
- sal_Bool ThreadPool::revokeQueue( const ByteSequence &aThreadId, sal_Bool bAsynchron )
+ bool ThreadPool::revokeQueue( const ByteSequence &aThreadId, bool bAsynchron )
{
MutexGuard guard( m_mutex );
@@ -233,7 +233,7 @@ namespace cppu_threadpool
if( ! (*ii).second.second->isEmpty() )
{
// another thread has put something into the queue
- return sal_False;
+ return false;
}
(*ii).second.second = 0;
@@ -249,7 +249,7 @@ namespace cppu_threadpool
if( ! (*ii).second.first->isEmpty() )
{
// another thread has put something into the queue
- return sal_False;
+ return false;
}
(*ii).second.first = 0;
}
@@ -259,17 +259,17 @@ namespace cppu_threadpool
m_mapQueue.erase( ii );
}
- return sal_True;
+ return true;
}
void ThreadPool::addJob(
const ByteSequence &aThreadId ,
- sal_Bool bAsynchron,
+ bool bAsynchron,
void *pThreadSpecificData,
RequestFun * doRequest )
{
- sal_Bool bCreateThread = sal_False;
+ bool bCreateThread = false;
JobQueue *pQueue = 0;
{
MutexGuard guard( m_mutex );
@@ -288,7 +288,7 @@ namespace cppu_threadpool
if( ! (*ii).second.second )
{
(*ii).second.second = new JobQueue();
- bCreateThread = sal_True;
+ bCreateThread = true;
}
pQueue = (*ii).second.second;
}
@@ -297,7 +297,7 @@ namespace cppu_threadpool
if( ! (*ii).second.first )
{
(*ii).second.first = new JobQueue();
- bCreateThread = sal_True;
+ bCreateThread = true;
}
pQueue = (*ii).second.first;
@@ -349,7 +349,7 @@ namespace cppu_threadpool
if( pQueue->isCallstackEmpty() )
{
- if( revokeQueue( aThreadId , sal_False) )
+ if( revokeQueue( aThreadId , false) )
{
// remove queue
delete pQueue;
@@ -370,7 +370,7 @@ using namespace cppu_threadpool;
struct uno_ThreadPool_Equal
{
- sal_Bool operator () ( const uno_ThreadPool &a , const uno_ThreadPool &b ) const
+ bool operator () ( const uno_ThreadPool &a , const uno_ThreadPool &b ) const
{
return a == b;
}
diff --git a/cppu/source/threadpool/threadpool.hxx b/cppu/source/threadpool/threadpool.hxx
index 18bb509486e7..2ee29ff5ddc6 100644
--- a/cppu/source/threadpool/threadpool.hxx
+++ b/cppu/source/threadpool/threadpool.hxx
@@ -90,7 +90,7 @@ namespace cppu_threadpool {
void dispose( sal_Int64 nDisposeId );
void destroy( sal_Int64 nDisposeId );
- sal_Bool isDisposed( sal_Int64 nDisposeId );
+ bool isDisposed( sal_Int64 nDisposeId );
private:
::osl::Mutex m_mutex;
@@ -128,7 +128,7 @@ namespace cppu_threadpool {
void destroy( sal_Int64 nDisposeId );
void addJob( const ByteSequence &aThreadId,
- sal_Bool bAsynchron,
+ bool bAsynchron,
void *pThreadSpecificData,
RequestFun * doRequest );
@@ -138,7 +138,7 @@ namespace cppu_threadpool {
/********
* @return true, if queue could be successfully revoked.
********/
- sal_Bool revokeQueue( const ByteSequence & aThreadId , sal_Bool bAsynchron );
+ bool revokeQueue( const ByteSequence & aThreadId , bool bAsynchron );
void waitInPool( rtl::Reference< ORequestThread > const & pThread );
@@ -147,7 +147,7 @@ namespace cppu_threadpool {
ThreadAdmin & getThreadAdmin() { return m_aThreadAdmin; }
private:
- void createThread( JobQueue *pQueue, const ByteSequence &aThreadId, sal_Bool bAsynchron);
+ void createThread( JobQueue *pQueue, const ByteSequence &aThreadId, bool bAsynchron);
ThreadIdHashMap m_mapQueue;
diff --git a/cppu/source/typelib/typelib.cxx b/cppu/source/typelib/typelib.cxx
index 1520bfa63ae4..25123c59b65a 100644
--- a/cppu/source/typelib/typelib.cxx
+++ b/cppu/source/typelib/typelib.cxx
@@ -99,7 +99,7 @@ static inline sal_Int32 newAlignedSize(
return (OldSize + NeededAlignment -1) / NeededAlignment * NeededAlignment + ElementSize;
}
-static inline sal_Bool reallyWeak( typelib_TypeClass eTypeClass )
+static inline bool reallyWeak( typelib_TypeClass eTypeClass )
SAL_THROW(())
{
return TYPELIB_TYPEDESCRIPTIONREFERENCE_ISREALLYWEAK( eTypeClass );
@@ -159,7 +159,7 @@ extern "C" void SAL_CALL typelib_typedescriptionreference_getByName(
//-----------------------------------------------------------------------------
struct equalStr_Impl
{
- sal_Bool operator()(const sal_Unicode * const & s1, const sal_Unicode * const & s2) const SAL_THROW(())
+ bool operator()(const sal_Unicode * const & s1, const sal_Unicode * const & s2) const SAL_THROW(())
{ return 0 == rtl_ustr_compare( s1, s2 ); }
};
@@ -1617,7 +1617,7 @@ extern "C" CPPU_DLLPUBLIC void SAL_CALL typelib_typedescription_register(
}
//------------------------------------------------------------------------
-static inline sal_Bool type_equals(
+static inline bool type_equals(
typelib_TypeDescriptionReference * p1, typelib_TypeDescriptionReference * p2 )
SAL_THROW(())
{
@@ -1888,7 +1888,7 @@ extern "C" CPPU_DLLPUBLIC void SAL_CALL typelib_typedescription_getByName(
*ppRet = 0;
}
- static sal_Bool bInited = sal_False;
+ static bool bInited = false;
TypeDescriptor_Init_Impl &rInit = Init::get();
if( !bInited )
@@ -1898,7 +1898,7 @@ extern "C" CPPU_DLLPUBLIC void SAL_CALL typelib_typedescription_getByName(
if( !bInited )
{
// avoid recursion during the next ...new calls
- bInited = sal_True;
+ bInited = true;
rtl_uString * pTypeName = 0;
typelib_TypeDescription * pType = 0;
@@ -2400,7 +2400,7 @@ extern "C" CPPU_DLLPUBLIC sal_Bool SAL_CALL typelib_typedescriptionreference_isA
TYPELIB_DANGER_RELEASE( pFromDescr );
return sal_False;
}
- sal_Bool bRet = typelib_typedescriptionreference_isAssignableFrom(
+ bool bRet = typelib_typedescriptionreference_isAssignableFrom(
pAssignable,
((typelib_TypeDescription *)((typelib_CompoundTypeDescription *)pFromDescr)->pBaseTypeDescription)->pWeakRef );
TYPELIB_DANGER_RELEASE( pFromDescr );
diff --git a/cppu/source/uno/assign.hxx b/cppu/source/uno/assign.hxx
index 655fe4c6d2e4..bd65d72df3d0 100644
--- a/cppu/source/uno/assign.hxx
+++ b/cppu/source/uno/assign.hxx
@@ -62,13 +62,13 @@ inline void * _queryInterface(
return pSource;
}
//==================================================================================================
-sal_Bool assignStruct(
+bool assignStruct(
void * pDest, void * pSource,
typelib_CompoundTypeDescription * pTypeDescr,
uno_QueryInterfaceFunc queryInterface, uno_AcquireFunc acquire, uno_ReleaseFunc release )
SAL_THROW(());
//--------------------------------------------------------------------------------------------------
-inline sal_Bool _assignStruct(
+inline bool _assignStruct(
void * pDest, void * pSource,
typelib_CompoundTypeDescription * pTypeDescr,
uno_QueryInterfaceFunc queryInterface, uno_AcquireFunc acquire, uno_ReleaseFunc release )
@@ -80,7 +80,7 @@ inline sal_Bool _assignStruct(
if (! assignStruct( pDest, pSource, pTypeDescr->pBaseTypeDescription,
queryInterface, acquire, release ))
{
- return sal_False;
+ return false;
}
}
// then copy members
@@ -95,13 +95,13 @@ inline sal_Bool _assignStruct(
ppTypeRefs[nDescr],
queryInterface, acquire, release ))
{
- return sal_False;
+ return false;
}
}
- return sal_True;
+ return true;
}
//--------------------------------------------------------------------------------------------------
-inline sal_Bool _assignData(
+inline bool _assignData(
void * pDest,
typelib_TypeDescriptionReference * pDestType, typelib_TypeDescription * pDestTypeDescr,
void * pSource,
@@ -116,7 +116,7 @@ inline sal_Bool _assignData(
{
_destructData( pDest, pDestType, pDestTypeDescr, release );
_defaultConstructData( pDest, pDestType, pDestTypeDescr );
- return sal_True;
+ return true;
}
while (typelib_TypeClass_ANY == pSourceType->eTypeClass)
{
@@ -124,7 +124,7 @@ inline sal_Bool _assignData(
pSourceType = ((uno_Any *)pSource)->pType;
pSource = ((uno_Any *)pSource)->pData;
if (pDest == pSource)
- return sal_True;
+ return true;
}
switch (pDestType->eTypeClass)
@@ -136,195 +136,195 @@ inline sal_Bool _assignData(
{
case typelib_TypeClass_CHAR:
*(sal_Unicode *)pDest = *(sal_Unicode *)pSource;
- return sal_True;
+ return true;
default:
- return sal_False;
+ return false;
}
case typelib_TypeClass_BOOLEAN:
switch (pSourceType->eTypeClass)
{
case typelib_TypeClass_BOOLEAN:
*(sal_Bool *)pDest = (*(sal_Bool *)pSource != sal_False);
- return sal_True;
+ return true;
default:
- return sal_False;
+ return false;
}
case typelib_TypeClass_BYTE:
switch (pSourceType->eTypeClass)
{
case typelib_TypeClass_BYTE:
*(sal_Int8 *)pDest = *(sal_Int8 *)pSource;
- return sal_True;
+ return true;
default:
- return sal_False;
+ return false;
}
case typelib_TypeClass_SHORT:
switch (pSourceType->eTypeClass)
{
case typelib_TypeClass_BYTE:
*(sal_Int16 *)pDest = *(sal_Int8 *)pSource;
- return sal_True;
+ return true;
case typelib_TypeClass_SHORT:
case typelib_TypeClass_UNSIGNED_SHORT:
*(sal_Int16 *)pDest = *(sal_Int16 *)pSource;
- return sal_True;
+ return true;
default:
- return sal_False;
+ return false;
}
case typelib_TypeClass_UNSIGNED_SHORT:
switch (pSourceType->eTypeClass)
{
case typelib_TypeClass_BYTE:
*(sal_uInt16 *)pDest = *(sal_Int8 *)pSource;
- return sal_True;
+ return true;
case typelib_TypeClass_SHORT:
case typelib_TypeClass_UNSIGNED_SHORT:
*(sal_uInt16 *)pDest = *(sal_uInt16 *)pSource;
- return sal_True;
+ return true;
default:
- return sal_False;
+ return false;
}
case typelib_TypeClass_LONG:
switch (pSourceType->eTypeClass)
{
case typelib_TypeClass_BYTE:
*(sal_Int32 *)pDest = *(sal_Int8 *)pSource;
- return sal_True;
+ return true;
case typelib_TypeClass_SHORT:
*(sal_Int32 *)pDest = *(sal_Int16 *)pSource;
- return sal_True;
+ return true;
case typelib_TypeClass_UNSIGNED_SHORT:
*(sal_Int32 *)pDest = *(sal_uInt16 *)pSource;
- return sal_True;
+ return true;
case typelib_TypeClass_LONG:
case typelib_TypeClass_UNSIGNED_LONG:
*(sal_Int32 *)pDest = *(sal_Int32 *)pSource;
- return sal_True;
+ return true;
default:
- return sal_False;
+ return false;
}
case typelib_TypeClass_UNSIGNED_LONG:
switch (pSourceType->eTypeClass)
{
case typelib_TypeClass_BYTE:
*(sal_uInt32 *)pDest = *(sal_Int8 *)pSource;
- return sal_True;
+ return true;
case typelib_TypeClass_SHORT:
*(sal_uInt32 *)pDest = *(sal_Int16 *)pSource;
- return sal_True;
+ return true;
case typelib_TypeClass_UNSIGNED_SHORT:
*(sal_uInt32 *)pDest = *(sal_uInt16 *)pSource;
- return sal_True;
+ return true;
case typelib_TypeClass_LONG:
case typelib_TypeClass_UNSIGNED_LONG:
*(sal_uInt32 *)pDest = *(sal_uInt32 *)pSource;
- return sal_True;
+ return true;
default:
- return sal_False;
+ return false;
}
case typelib_TypeClass_HYPER:
switch (pSourceType->eTypeClass)
{
case typelib_TypeClass_BYTE:
*(sal_Int64 *)pDest = *(sal_Int8 *)pSource;
- return sal_True;
+ return true;
case typelib_TypeClass_SHORT:
*(sal_Int64 *)pDest = *(sal_Int16 *)pSource;
- return sal_True;
+ return true;
case typelib_TypeClass_UNSIGNED_SHORT:
*(sal_Int64 *)pDest = *(sal_uInt16 *)pSource;
- return sal_True;
+ return true;
case typelib_TypeClass_LONG:
*(sal_Int64 *)pDest = *(sal_Int32 *)pSource;
- return sal_True;
+ return true;
case typelib_TypeClass_UNSIGNED_LONG:
*(sal_Int64 *)pDest = *(sal_uInt32 *)pSource;
- return sal_True;
+ return true;
case typelib_TypeClass_HYPER:
case typelib_TypeClass_UNSIGNED_HYPER:
*(sal_Int64 *)pDest = *(sal_Int64 *)pSource;
- return sal_True;
+ return true;
default:
- return sal_False;
+ return false;
}
case typelib_TypeClass_UNSIGNED_HYPER:
switch (pSourceType->eTypeClass)
{
case typelib_TypeClass_BYTE:
*(sal_uInt64 *)pDest = *(sal_Int8 *)pSource;
- return sal_True;
+ return true;
case typelib_TypeClass_SHORT:
*(sal_uInt64 *)pDest = *(sal_Int16 *)pSource;
- return sal_True;
+ return true;
case typelib_TypeClass_UNSIGNED_SHORT:
*(sal_uInt64 *)pDest = *(sal_uInt16 *)pSource;
- return sal_True;
+ return true;
case typelib_TypeClass_LONG:
*(sal_uInt64 *)pDest = *(sal_Int32 *)pSource;
- return sal_True;
+ return true;
case typelib_TypeClass_UNSIGNED_LONG:
*(sal_uInt64 *)pDest = *(sal_uInt32 *)pSource;
- return sal_True;
+ return true;
case typelib_TypeClass_HYPER:
case typelib_TypeClass_UNSIGNED_HYPER:
*(sal_uInt64 *)pDest = *(sal_uInt64 *)pSource;
- return sal_True;
+ return true;
default:
- return sal_False;
+ return false;
}
case typelib_TypeClass_FLOAT:
switch (pSourceType->eTypeClass)
{
case typelib_TypeClass_BYTE:
*(float *)pDest = *(sal_Int8 *)pSource;
- return sal_True;
+ return true;
case typelib_TypeClass_SHORT:
*(float *)pDest = *(sal_Int16 *)pSource;
- return sal_True;
+ return true;
case typelib_TypeClass_UNSIGNED_SHORT:
*(float *)pDest = *(sal_uInt16 *)pSource;
- return sal_True;
+ return true;
case typelib_TypeClass_FLOAT:
*(float *)pDest = *(float *)pSource;
- return sal_True;
+ return true;
default:
- return sal_False;
+ return false;
}
case typelib_TypeClass_DOUBLE:
switch (pSourceType->eTypeClass)
{
case typelib_TypeClass_BYTE:
*(double *)pDest = *(sal_Int8 *)pSource;
- return sal_True;
+ return true;
case typelib_TypeClass_SHORT:
*(double *)pDest = *(sal_Int16 *)pSource;
- return sal_True;
+ return true;
case typelib_TypeClass_UNSIGNED_SHORT:
*(double *)pDest = *(sal_uInt16 *)pSource;
- return sal_True;
+ return true;
case typelib_TypeClass_LONG:
*(double *)pDest = *(sal_Int32 *)pSource;
- return sal_True;
+ return true;
case typelib_TypeClass_UNSIGNED_LONG:
*(double *)pDest = *(sal_uInt32 *)pSource;
- return sal_True;
+ return true;
case typelib_TypeClass_FLOAT:
*(double *)pDest = *(float *)pSource;
- return sal_True;
+ return true;
case typelib_TypeClass_DOUBLE:
*(double *)pDest = *(double *)pSource;
- return sal_True;
+ return true;
default:
- return sal_False;
+ return false;
}
case typelib_TypeClass_STRING:
switch (pSourceType->eTypeClass)
{
case typelib_TypeClass_STRING:
::rtl_uString_assign( (rtl_uString **)pDest, *(rtl_uString **)pSource );
- return sal_True;
+ return true;
default:
- return sal_False;
+ return false;
}
case typelib_TypeClass_TYPE:
switch (pSourceType->eTypeClass)
@@ -335,28 +335,28 @@ inline sal_Bool _assignData(
::typelib_typedescriptionreference_release( *pp );
*pp = *(typelib_TypeDescriptionReference **)pSource;
TYPE_ACQUIRE( *pp );
- return sal_True;
+ return true;
}
default:
- return sal_False;
+ return false;
}
case typelib_TypeClass_ANY:
_destructAny( (uno_Any *)pDest, release );
_copyConstructAny( (uno_Any *)pDest, pSource, pSourceType, pSourceTypeDescr, acquire, 0 );
- return sal_True;
+ return true;
case typelib_TypeClass_ENUM:
if (_type_equals( pDestType, pSourceType ))
{
*(sal_Int32 *)pDest = *(sal_Int32 *)pSource;
- return sal_True;
+ return true;
}
- return sal_False;
+ return false;
case typelib_TypeClass_STRUCT:
case typelib_TypeClass_EXCEPTION:
if (typelib_TypeClass_STRUCT == pSourceType->eTypeClass ||
typelib_TypeClass_EXCEPTION == pSourceType->eTypeClass)
{
- sal_Bool bRet = sal_False;
+ bool bRet = false;
if (pSourceTypeDescr)
{
typelib_CompoundTypeDescription * pTypeDescr =
@@ -393,29 +393,29 @@ inline sal_Bool _assignData(
}
return bRet;
}
- return sal_False;
+ return false;
case typelib_TypeClass_SEQUENCE:
if (typelib_TypeClass_SEQUENCE != pSourceType->eTypeClass)
- return sal_False;
+ return false;
// self assignment:
if (*(uno_Sequence **)pSource == *(uno_Sequence **)pDest)
- return sal_True;
+ return true;
if (_type_equals( pDestType, pSourceType ))
{
osl_atomic_increment( &(*(uno_Sequence **)pSource)->nRefCount );
idestructSequence(
*(uno_Sequence **)pDest, pDestType, pDestTypeDescr, release );
*(uno_Sequence **)pDest = *(uno_Sequence **)pSource;
- return sal_True;
+ return true;
}
- return sal_False;
+ return false;
case typelib_TypeClass_INTERFACE:
if (typelib_TypeClass_INTERFACE != pSourceType->eTypeClass)
- return sal_False;
+ return false;
if (_type_equals( pDestType, pSourceType ))
{
_assignInterface( (void **)pDest, *(void **)pSource, acquire, release );
- return sal_True;
+ return true;
}
else if (*static_cast< void ** >(pSource) == 0)
{
@@ -455,7 +455,7 @@ inline sal_Bool _assignData(
}
default:
OSL_ASSERT(false);
- return sal_False;
+ return false;
}
}
diff --git a/cppu/source/uno/data.cxx b/cppu/source/uno/data.cxx
index 5c29088a049f..da358d62a141 100644
--- a/cppu/source/uno/data.cxx
+++ b/cppu/source/uno/data.cxx
@@ -140,7 +140,7 @@ void destructStruct(
_destructStruct( pValue, pTypeDescr, release );
}
//==================================================================================================
-sal_Bool equalStruct(
+bool equalStruct(
void * pDest, void *pSource,
typelib_CompoundTypeDescription * pTypeDescr,
uno_QueryInterfaceFunc queryInterface, uno_ReleaseFunc release )
@@ -149,7 +149,7 @@ sal_Bool equalStruct(
return _equalStruct( pDest, pSource, pTypeDescr, queryInterface, release );
}
//==================================================================================================
-sal_Bool assignStruct(
+bool assignStruct(
void * pDest, void * pSource,
typelib_CompoundTypeDescription * pTypeDescr,
uno_QueryInterfaceFunc queryInterface, uno_AcquireFunc acquire, uno_ReleaseFunc release )
@@ -178,7 +178,7 @@ void destructSequence(
}
//==================================================================================================
-sal_Bool equalSequence(
+bool equalSequence(
uno_Sequence * pDest, uno_Sequence * pSource,
typelib_TypeDescriptionReference * pElementType,
uno_QueryInterfaceFunc queryInterface, uno_ReleaseFunc release )
diff --git a/cppu/source/uno/eq.hxx b/cppu/source/uno/eq.hxx
index c1496cb77900..482a1979d1b8 100644
--- a/cppu/source/uno/eq.hxx
+++ b/cppu/source/uno/eq.hxx
@@ -33,16 +33,16 @@ namespace cppu
//##################################################################################################
//--------------------------------------------------------------------------------------------------
-inline sal_Bool _equalObject(
+inline bool _equalObject(
void * pI1, void * pI2,
uno_QueryInterfaceFunc queryInterface, uno_ReleaseFunc release )
SAL_THROW(())
{
if (pI1 == pI2)
- return sal_True;
+ return true;
if ((0 == pI1) || (0 == pI2))
- return sal_False;
- sal_Bool bRet = sal_False;
+ return false;
+ bool bRet = false;
typelib_TypeDescriptionReference * type_XInterface =
* typelib_static_type_getByTypeClass( typelib_TypeClass_INTERFACE );
@@ -63,13 +63,13 @@ inline sal_Bool _equalObject(
}
//==================================================================================================
-sal_Bool equalStruct(
+bool equalStruct(
void * pDest, void *pSource,
typelib_CompoundTypeDescription * pTypeDescr,
uno_QueryInterfaceFunc queryInterface, uno_ReleaseFunc release )
SAL_THROW(());
//--------------------------------------------------------------------------------------------------
-inline sal_Bool _equalStruct(
+inline bool _equalStruct(
void * pDest, void *pSource,
typelib_CompoundTypeDescription * pTypeDescr,
uno_QueryInterfaceFunc queryInterface, uno_ReleaseFunc release )
@@ -78,7 +78,7 @@ inline sal_Bool _equalStruct(
if (pTypeDescr->pBaseTypeDescription &&
!equalStruct( pDest, pSource, pTypeDescr->pBaseTypeDescription, queryInterface, release ))
{
- return sal_False;
+ return false;
}
typelib_TypeDescriptionReference ** ppTypeRefs = pTypeDescr->ppTypeRefs;
@@ -94,31 +94,31 @@ inline sal_Bool _equalStruct(
ppTypeRefs[nDescr],
queryInterface, release ))
{
- return sal_False;
+ return false;
}
}
- return sal_True;
+ return true;
}
//==================================================================================================
-sal_Bool equalSequence(
+bool equalSequence(
uno_Sequence * pDest, uno_Sequence * pSource,
typelib_TypeDescriptionReference * pElementType,
uno_QueryInterfaceFunc queryInterface, uno_ReleaseFunc release )
SAL_THROW(());
//--------------------------------------------------------------------------------------------------
-inline sal_Bool _equalSequence(
+inline bool _equalSequence(
uno_Sequence * pDest, uno_Sequence * pSource,
typelib_TypeDescriptionReference * pElementType,
uno_QueryInterfaceFunc queryInterface, uno_ReleaseFunc release )
SAL_THROW(())
{
if (pDest == pSource)
- return sal_True;
+ return true;
sal_Int32 nElements = pDest->nElements;
if (nElements != pSource->nElements)
- return sal_False;
+ return false;
if (! nElements)
- return sal_True;
+ return true;
void * pDestElements = pDest->elements;
void * pSourceElements = pSource->elements;
@@ -134,10 +134,10 @@ inline sal_Bool _equalSequence(
if ((((sal_Bool *)pDestElements)[nPos] != sal_False) !=
(((sal_Bool *)pSourceElements)[nPos] != sal_False))
{
- return sal_False;
+ return false;
}
}
- return sal_True;
+ return true;
}
case typelib_TypeClass_BYTE:
return (0 == memcmp( pDestElements, pSourceElements, sizeof(sal_Int8) * nElements ));
@@ -155,27 +155,27 @@ inline sal_Bool _equalSequence(
for ( sal_Int32 nPos = nElements; nPos--; )
{
if (((float *)pDestElements)[nPos] != ((float *)pSourceElements)[nPos])
- return sal_False;
+ return false;
}
- return sal_True;
+ return true;
}
case typelib_TypeClass_DOUBLE:
{
for ( sal_Int32 nPos = nElements; nPos--; )
{
if (((double *)pDestElements)[nPos] != ((double *)pSourceElements)[nPos])
- return sal_False;
+ return false;
}
- return sal_True;
+ return true;
}
case typelib_TypeClass_STRING:
{
for ( sal_Int32 nPos = nElements; nPos--; )
{
if (! ((::rtl::OUString *)pDestElements +nPos)->equals( ((const ::rtl::OUString *)pSourceElements)[nPos] ))
- return sal_False;
+ return false;
}
- return sal_True;
+ return true;
}
case typelib_TypeClass_TYPE:
{
@@ -184,10 +184,10 @@ inline sal_Bool _equalSequence(
if (! _type_equals( ((typelib_TypeDescriptionReference **)pDestElements)[nPos],
((typelib_TypeDescriptionReference **)pSourceElements)[nPos] ))
{
- return sal_False;
+ return false;
}
}
- return sal_True;
+ return true;
}
case typelib_TypeClass_ANY:
{
@@ -199,10 +199,10 @@ inline sal_Bool _equalSequence(
pSource2->pData, pSource2->pType,
queryInterface, release ))
{
- return sal_False;
+ return false;
}
}
- return sal_True;
+ return true;
}
case typelib_TypeClass_ENUM:
return (0 == memcmp( pDestElements, pSourceElements, sizeof(sal_Int32) * nElements ));
@@ -220,11 +220,11 @@ inline sal_Bool _equalSequence(
queryInterface, release ))
{
TYPELIB_DANGER_RELEASE( pElementTypeDescr );
- return sal_False;
+ return false;
}
}
TYPELIB_DANGER_RELEASE( pElementTypeDescr );
- return sal_True;
+ return true;
}
case typelib_TypeClass_SEQUENCE: // sequence of sequence
{
@@ -239,11 +239,11 @@ inline sal_Bool _equalSequence(
pSeqElementType, queryInterface, release ))
{
TYPELIB_DANGER_RELEASE( pElementTypeDescr );
- return sal_False;
+ return false;
}
}
TYPELIB_DANGER_RELEASE( pElementTypeDescr );
- return sal_True;
+ return true;
}
case typelib_TypeClass_INTERFACE:
{
@@ -252,18 +252,18 @@ inline sal_Bool _equalSequence(
if (! _equalObject( ((void **)pDestElements)[nPos], ((void **)pSourceElements)[nPos],
queryInterface, release ))
{
- return sal_False;
+ return false;
}
}
- return sal_True;
+ return true;
}
default:
OSL_ASSERT(false);
- return sal_False;
+ return false;
}
}
//--------------------------------------------------------------------------------------------------
-inline sal_Bool _equalData(
+inline bool _equalData(
void * pDest,
typelib_TypeDescriptionReference * pDestType, typelib_TypeDescription * pDestTypeDescr,
void * pSource,
@@ -318,7 +318,7 @@ inline sal_Bool _equalData(
case typelib_TypeClass_DOUBLE:
return ((double)*(sal_Int8 *)pDest == *(double *)pSource);
default:
- return sal_False;
+ return false;
}
case typelib_TypeClass_SHORT:
switch (eSourceTypeClass)
@@ -343,7 +343,7 @@ inline sal_Bool _equalData(
case typelib_TypeClass_DOUBLE:
return ((double)*(sal_Int16 *)pDest == *(double *)pSource);
default:
- return sal_False;
+ return false;
}
case typelib_TypeClass_UNSIGNED_SHORT:
switch (eSourceTypeClass)
@@ -367,7 +367,7 @@ inline sal_Bool _equalData(
case typelib_TypeClass_DOUBLE:
return ((double)*(sal_uInt16 *)pDest == *(double *)pSource);
default:
- return sal_False;
+ return false;
}
case typelib_TypeClass_LONG:
switch (eSourceTypeClass)
@@ -392,7 +392,7 @@ inline sal_Bool _equalData(
case typelib_TypeClass_DOUBLE:
return ((double)*(sal_Int32 *)pDest == *(double *)pSource);
default:
- return sal_False;
+ return false;
}
case typelib_TypeClass_UNSIGNED_LONG:
switch (eSourceTypeClass)
@@ -416,7 +416,7 @@ inline sal_Bool _equalData(
case typelib_TypeClass_DOUBLE:
return ((double)*(sal_uInt32 *)pDest == *(double *)pSource);
default:
- return sal_False;
+ return false;
}
case typelib_TypeClass_HYPER:
switch (eSourceTypeClass)
@@ -441,7 +441,7 @@ inline sal_Bool _equalData(
case typelib_TypeClass_DOUBLE:
return ((double)*(sal_Int64 *)pDest == *(double *)pSource);
default:
- return sal_False;
+ return false;
}
case typelib_TypeClass_UNSIGNED_HYPER:
switch (eSourceTypeClass)
@@ -466,14 +466,14 @@ inline sal_Bool _equalData(
return (*(sal_uInt64 *)pDest == *(sal_uInt64 *)pSource);
case typelib_TypeClass_FLOAT:
if (::floor( *(float *)pSource ) != *(float *)pSource || *(float *)pSource < 0)
- return sal_False;
+ return false;
return (*(sal_uInt64 *)pDest == (sal_uInt64)*(float *)pSource);
case typelib_TypeClass_DOUBLE:
if (::floor( *(double *)pSource ) != *(double *)pSource || *(double *)pSource < 0)
- return sal_False;
+ return false;
return (*(sal_uInt64 *)pDest == (sal_uInt64)*(double *)pSource);
default:
- return sal_False;
+ return false;
}
case typelib_TypeClass_FLOAT:
switch (eSourceTypeClass)
@@ -492,14 +492,14 @@ inline sal_Bool _equalData(
return (*(float *)pDest == (float)*(sal_Int64 *)pSource);
case typelib_TypeClass_UNSIGNED_HYPER:
if (::floor( *(float *)pDest ) != *(float *)pDest || *(float *)pDest < 0)
- return sal_False;
+ return false;
return ((sal_uInt64)*(float *)pDest == *(sal_uInt64 *)pSource);
case typelib_TypeClass_FLOAT:
return (*(float *)pDest == *(float *)pSource);
case typelib_TypeClass_DOUBLE:
return ((double)*(float *)pDest == *(double *)pSource);
default:
- return sal_False;
+ return false;
}
case typelib_TypeClass_DOUBLE:
switch (eSourceTypeClass)
@@ -518,14 +518,14 @@ inline sal_Bool _equalData(
return (*(double *)pDest == (double)*(sal_Int64 *)pSource);
case typelib_TypeClass_UNSIGNED_HYPER:
if (::floor( *(double *)pDest ) != *(double *)pDest || *(double *)pDest < 0)
- return sal_False;
+ return false;
return ((sal_uInt64)*(double *)pDest == *(sal_uInt64 *)pSource);
case typelib_TypeClass_FLOAT:
return (*(double *)pDest == (double)*(float *)pSource);
case typelib_TypeClass_DOUBLE:
return (*(double *)pDest == *(double *)pSource);
default:
- return sal_False;
+ return false;
}
case typelib_TypeClass_STRING:
return eSourceTypeClass == typelib_TypeClass_STRING
@@ -542,7 +542,7 @@ inline sal_Bool _equalData(
case typelib_TypeClass_STRUCT:
case typelib_TypeClass_EXCEPTION:
if (! _type_equals( pDestType, pSourceType ))
- return sal_False;
+ return false;
if (pDestTypeDescr)
{
return _equalStruct(
@@ -553,7 +553,7 @@ inline sal_Bool _equalData(
else
{
TYPELIB_DANGER_GET( &pDestTypeDescr, pDestType );
- sal_Bool bRet = _equalStruct(
+ bool bRet = _equalStruct(
pDest, pSource,
(typelib_CompoundTypeDescription *)pDestTypeDescr,
queryInterface, release );
@@ -573,7 +573,7 @@ inline sal_Bool _equalData(
else
{
TYPELIB_DANGER_GET( &pDestTypeDescr, pDestType );
- sal_Bool bRet = _equalSequence(
+ bool bRet = _equalSequence(
*(uno_Sequence **)pDest, *(uno_Sequence **)pSource,
((typelib_IndirectTypeDescription *)pDestTypeDescr)->pType,
queryInterface, release );
@@ -581,7 +581,7 @@ inline sal_Bool _equalData(
return bRet;
}
}
- return sal_False;
+ return false;
case typelib_TypeClass_INTERFACE:
if (typelib_TypeClass_INTERFACE == eSourceTypeClass)
return _equalObject( *(void **)pDest, *(void **)pSource, queryInterface, release );
@@ -590,7 +590,7 @@ inline sal_Bool _equalData(
OSL_ASSERT(false);
break;
}
- return sal_False;
+ return false;
}
}
diff --git a/cppu/source/uno/lbmap.cxx b/cppu/source/uno/lbmap.cxx
index e380248bf6bb..aa8cde9dde7c 100644
--- a/cppu/source/uno/lbmap.cxx
+++ b/cppu/source/uno/lbmap.cxx
@@ -68,7 +68,7 @@ public:
{ return operator = ( rMapping._pMapping ); }
inline uno_Mapping * SAL_CALL get() const SAL_THROW(())
{ return _pMapping; }
- inline sal_Bool SAL_CALL is() const SAL_THROW(())
+ inline bool SAL_CALL is() const SAL_THROW(())
{ return (_pMapping != 0); }
};
//__________________________________________________________________________________________________
@@ -356,7 +356,7 @@ static uno_ext_getMappingFunc selectMapFunc( const OUString & rBridgeName )
static inline oslModule loadModule( const OUString & rBridgeName )
SAL_THROW(())
{
- sal_Bool bNeg;
+ bool bNeg;
{
MappingsData & rData = getMappingsData();
MutexGuard aGuard( rData.aNegativeLibsMutex );
diff --git a/cppu/source/uno/prim.hxx b/cppu/source/uno/prim.hxx
index 5be342a6ca25..c0b6804babbb 100644
--- a/cppu/source/uno/prim.hxx
+++ b/cppu/source/uno/prim.hxx
@@ -151,7 +151,7 @@ extern "C" void * binuno_queryInterface(
void * pUnoI, typelib_TypeDescriptionReference * pDestType );
//--------------------------------------------------------------------------------------------------
-inline sal_Bool _type_equals(
+inline bool _type_equals(
typelib_TypeDescriptionReference * pType1, typelib_TypeDescriptionReference * pType2 )
SAL_THROW(())
{