summaryrefslogtreecommitdiff
path: root/sal/rtl
diff options
context:
space:
mode:
authorStephan Bergmann <sbergman@redhat.com>2014-02-14 22:45:44 +0100
committerStephan Bergmann <sbergman@redhat.com>2014-02-17 17:55:16 +0100
commitd84cf2de01f17f2617846135081a819ce74dd87a (patch)
tree192bc83388393b8daefe0dd8b1610c50f111a7bd /sal/rtl
parent6f69fb5d7d7f66d17b56eca5a5b3f494c597b97a (diff)
sal: sal_Bool -> bool
Change-Id: I071a931660dafc1ee5950da527b042fb175255b8
Diffstat (limited to 'sal/rtl')
-rw-r--r--sal/rtl/bootstrap.cxx8
-rw-r--r--sal/rtl/byteseq.cxx6
-rw-r--r--sal/rtl/random.cxx8
-rw-r--r--sal/rtl/strimp.cxx10
-rw-r--r--sal/rtl/strimp.hxx2
-rw-r--r--sal/rtl/string.cxx14
-rw-r--r--sal/rtl/strtmpl.cxx6
-rw-r--r--sal/rtl/ustring.cxx2
8 files changed, 28 insertions, 28 deletions
diff --git a/sal/rtl/bootstrap.cxx b/sal/rtl/bootstrap.cxx
index 27d8d52befb6..43275c37d55c 100644
--- a/sal/rtl/bootstrap.cxx
+++ b/sal/rtl/bootstrap.cxx
@@ -158,7 +158,7 @@ namespace {
//----------------------------------------------------------------------------
-static sal_Bool getFromCommandLineArgs(
+static bool getFromCommandLineArgs(
rtl::OUString const & key, rtl::OUString * value )
{
OSL_ASSERT(value != NULL);
@@ -202,7 +202,7 @@ static sal_Bool getFromCommandLineArgs(
pNameValueList = &nameValueList;
}
- sal_Bool found = sal_False;
+ bool found = false;
for( NameValueList::iterator ii = pNameValueList->begin() ;
ii != pNameValueList->end() ;
@@ -211,7 +211,7 @@ static sal_Bool getFromCommandLineArgs(
if( (*ii).sName.equals(key) )
{
*value = (*ii).sValue;
- found = sal_True;
+ found = true;
break;
}
}
@@ -761,7 +761,7 @@ sal_Bool SAL_CALL rtl_bootstrap_get_from_handle(
{
osl::MutexGuard guard( osl::Mutex::getGlobalMutex() );
- sal_Bool found = sal_False;
+ bool found = false;
if(ppValue && pName)
{
if (handle == 0)
diff --git a/sal/rtl/byteseq.cxx b/sal/rtl/byteseq.cxx
index dfc0d96158be..10f2546fa024 100644
--- a/sal/rtl/byteseq.cxx
+++ b/sal/rtl/byteseq.cxx
@@ -234,10 +234,10 @@ sal_Bool SAL_CALL rtl_byte_sequence_equals( sal_Sequence *pSequence1 , sal_Seque
{
return sal_False;
}
- return (sal_Bool)
- (memcmp(
+ return
+ memcmp(
pSequence1->elements, pSequence2->elements, pSequence1->nElements )
- == 0);
+ == 0;
}
diff --git a/sal/rtl/random.cxx b/sal/rtl/random.cxx
index 447ded5a23c6..53cce865e822 100644
--- a/sal/rtl/random.cxx
+++ b/sal/rtl/random.cxx
@@ -76,7 +76,7 @@ struct RandomPool_Impl
/** __rtl_random_initPool.
*/
-static sal_Bool __rtl_random_initPool (
+static bool __rtl_random_initPool (
RandomPool_Impl *pImpl);
/** __rtl_random_seedPool.
@@ -108,7 +108,7 @@ static double __rtl_random_data (RandomData_Impl *pImpl)
/*
* __rtl_random_initPool.
*/
-static sal_Bool __rtl_random_initPool (RandomPool_Impl *pImpl)
+static bool __rtl_random_initPool (RandomPool_Impl *pImpl)
{
pImpl->m_hDigest = rtl_digest_create (RTL_RANDOM_DIGEST);
if (pImpl->m_hDigest)
@@ -148,9 +148,9 @@ static sal_Bool __rtl_random_initPool (RandomPool_Impl *pImpl)
seed = __rtl_random_data (&rd);
__rtl_random_seedPool (pImpl, (sal_uInt8*)&seed, sizeof(seed));
}
- return sal_True;
+ return true;
}
- return sal_False;
+ return false;
}
/*
diff --git a/sal/rtl/strimp.cxx b/sal/rtl/strimp.cxx
index da728ae4fb17..db554644f6a9 100644
--- a/sal/rtl/strimp.cxx
+++ b/sal/rtl/strimp.cxx
@@ -31,22 +31,22 @@ sal_Int16 rtl_ImplGetDigit( sal_Unicode ch, sal_Int16 nRadix )
return (n < nRadix) ? n : -1;
}
-sal_Bool rtl_ImplIsWhitespace( sal_Unicode c )
+bool rtl_ImplIsWhitespace( sal_Unicode c )
{
/* Space or Control character? */
if ( (c <= 32) && c )
- return sal_True;
+ return true;
/* Only in the General Punctuation area Space or Control characters are included? */
if ( (c < 0x2000) || (c > 0x206F) )
- return sal_False;
+ return false;
if ( ((c >= 0x2000) && (c <= 0x200B)) || /* All Spaces */
(c == 0x2028) || /* LINE SEPARATOR */
(c == 0x2029) ) /* PARAGRAPH SEPARATOR */
- return sal_True;
+ return true;
- return sal_False;
+ return false;
}
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sal/rtl/strimp.hxx b/sal/rtl/strimp.hxx
index 997d72c4c814..e31717c39539 100644
--- a/sal/rtl/strimp.hxx
+++ b/sal/rtl/strimp.hxx
@@ -48,7 +48,7 @@
sal_Int16 rtl_ImplGetDigit( sal_Unicode ch, sal_Int16 nRadix );
-sal_Bool rtl_ImplIsWhitespace( sal_Unicode c );
+bool rtl_ImplIsWhitespace( sal_Unicode c );
// string lifetime instrumentation / diagnostics
#if USE_SDT_PROBES
diff --git a/sal/rtl/string.cxx b/sal/rtl/string.cxx
index 32ef07753560..9a651b65617a 100644
--- a/sal/rtl/string.cxx
+++ b/sal/rtl/string.cxx
@@ -173,12 +173,12 @@ static int rtl_ImplGetFastUTF8ByteLen( const sal_Unicode* pStr, sal_Int32 nLen )
/* ----------------------------------------------------------------------- */
-sal_Bool SAL_CALL rtl_impl_convertUStringToString(rtl_String ** pTarget,
+bool SAL_CALL rtl_impl_convertUStringToString(rtl_String ** pTarget,
sal_Unicode const * pSource,
sal_Int32 nLength,
rtl_TextEncoding nEncoding,
sal_uInt32 nFlags,
- sal_Bool bCheckErrors)
+ bool bCheckErrors)
{
OSL_ASSERT(pTarget != NULL
&& (pSource != NULL || nLength == 0)
@@ -225,7 +225,7 @@ sal_Bool SAL_CALL rtl_impl_convertUStringToString(rtl_String ** pTarget,
nLength--;
}
while ( nLength );
- return sal_True;
+ return true;
}
nMaxCharLen = 4;
@@ -260,7 +260,7 @@ sal_Bool SAL_CALL rtl_impl_convertUStringToString(rtl_String ** pTarget,
{
rtl_freeMemory(pTemp);
rtl_destroyUnicodeToTextConverter(hConverter);
- return sal_False;
+ return false;
}
if ((nInfo & RTL_UNICODETOTEXT_INFO_DESTBUFFERTOSMALL) == 0)
@@ -301,7 +301,7 @@ sal_Bool SAL_CALL rtl_impl_convertUStringToString(rtl_String ** pTarget,
if ( pTemp && !nDestBytes )
rtl_string_new( pTarget );
}
- return sal_True;
+ return true;
}
void SAL_CALL rtl_uString2String( rtl_String** ppThis,
@@ -312,7 +312,7 @@ void SAL_CALL rtl_uString2String( rtl_String** ppThis,
SAL_THROW_EXTERN_C()
{
rtl_impl_convertUStringToString(ppThis, pUStr, nULen, eTextEncoding,
- nCvtFlags, sal_False);
+ nCvtFlags, false);
}
sal_Bool SAL_CALL rtl_convertUStringToString(rtl_String ** pTarget,
@@ -323,7 +323,7 @@ sal_Bool SAL_CALL rtl_convertUStringToString(rtl_String ** pTarget,
SAL_THROW_EXTERN_C()
{
return rtl_impl_convertUStringToString(pTarget, pSource, nLength, nEncoding,
- nFlags, sal_True);
+ nFlags, true);
}
void rtl_string_newReplaceFirst(
diff --git a/sal/rtl/strtmpl.cxx b/sal/rtl/strtmpl.cxx
index f2eac10bf217..a9eb665e9216 100644
--- a/sal/rtl/strtmpl.cxx
+++ b/sal/rtl/strtmpl.cxx
@@ -898,7 +898,7 @@ namespace {
sal_Int16 nRadix )
{
BOOST_STATIC_ASSERT(std::numeric_limits<T>::is_signed);
- sal_Bool bNeg;
+ bool bNeg;
sal_Int16 nDigit;
U n = 0;
@@ -911,14 +911,14 @@ namespace {
if ( *pStr == '-' )
{
- bNeg = sal_True;
+ bNeg = true;
pStr++;
}
else
{
if ( *pStr == '+' )
pStr++;
- bNeg = sal_False;
+ bNeg = false;
}
T nDiv;
diff --git a/sal/rtl/ustring.cxx b/sal/rtl/ustring.cxx
index d31d6bc592dc..8c9760c8bb60 100644
--- a/sal/rtl/ustring.cxx
+++ b/sal/rtl/ustring.cxx
@@ -1026,7 +1026,7 @@ sal_Bool rtl_convertStringToUString(
{
sal_uInt32 info;
rtl_string2UString_status(target, source, length, encoding, flags, &info);
- return (sal_Bool) ((info & RTL_TEXTTOUNICODE_INFO_ERROR) == 0);
+ return (info & RTL_TEXTTOUNICODE_INFO_ERROR) == 0;
}
void rtl_uString_newReplaceFirst(