diff options
author | erihel <erihel@gmail.com> | 2012-09-22 11:48:41 +0200 |
---|---|---|
committer | erihel <erihel@gmail.com> | 2012-09-22 11:48:41 +0200 |
commit | 37e7c73f439c0d8cbfd0f1c02b7ef5916fd748ae (patch) | |
tree | b8a0fbe82a8903f9d6591e0cd464e4c7a5c61fa1 /lib/simpleini | |
parent | 0ff419560d5a567afaa0294968cc1f5b5e6b597b (diff) | |
download | colobot-37e7c73f439c0d8cbfd0f1c02b7ef5916fd748ae.tar.gz colobot-37e7c73f439c0d8cbfd0f1c02b7ef5916fd748ae.tar.bz2 colobot-37e7c73f439c0d8cbfd0f1c02b7ef5916fd748ae.zip |
* Removed some warnings
Diffstat (limited to 'lib/simpleini')
-rw-r--r-- | lib/simpleini/SimpleIni.h | 18 |
1 files changed, 9 insertions, 9 deletions
diff --git a/lib/simpleini/SimpleIni.h b/lib/simpleini/SimpleIni.h index c75408e..ab4749f 100644 --- a/lib/simpleini/SimpleIni.h +++ b/lib/simpleini/SimpleIni.h @@ -2861,16 +2861,16 @@ public: // the distribution but are publically available from unicode.org
// at http://www.unicode.org/Public/PROGRAMS/CVTUTF/
ConversionResult retval;
- const UTF8 * pUtf8 = (const UTF8 *) a_pInputData;
+ const UTF8 * pUtf8 = static_cast<const UTF8 *>(a_pInputData);
if (sizeof(wchar_t) == sizeof(UTF32)) {
- UTF32 * pUtf32 = (UTF32 *) a_pOutputData;
+ UTF32 * pUtf32 = static_cast<UTF32 *>(a_pOutputData);
retval = ConvertUTF8toUTF32(
&pUtf8, pUtf8 + a_uInputDataLen,
&pUtf32, pUtf32 + a_uOutputDataSize,
lenientConversion);
}
else if (sizeof(wchar_t) == sizeof(UTF16)) {
- UTF16 * pUtf16 = (UTF16 *) a_pOutputData;
+ UTF16 * pUtf16 = static_cast<UTF16 *>(a_pOutputData);
retval = ConvertUTF8toUTF16(
&pUtf8, pUtf8 + a_uInputDataLen,
&pUtf16, pUtf16 + a_uOutputDataSize,
@@ -2881,7 +2881,7 @@ public: else {
size_t retval = mbstowcs(a_pOutputData,
a_pInputData, a_uOutputDataSize);
- return retval != (size_t)(-1);
+ return retval != static_cast<size_t>(-1);
}
}
@@ -2908,7 +2908,7 @@ public: }
else {
size_t uLen = wcstombs(NULL, a_pInputData, 0);
- if (uLen == (size_t)(-1)) {
+ if (uLen == static_cast<size_t>(-1)) {
return uLen;
}
return uLen + 1; // include NULL terminator
@@ -2948,16 +2948,16 @@ public: // the distribution but are publically available from unicode.org
// at http://www.unicode.org/Public/PROGRAMS/CVTUTF/
ConversionResult retval;
- UTF8 * pUtf8 = (UTF8 *) a_pOutputData;
+ UTF8 * pUtf8 = static_cast<UTF8 *> (a_pOutputData);
if (sizeof(wchar_t) == sizeof(UTF32)) {
- const UTF32 * pUtf32 = (const UTF32 *) a_pInputData;
+ const UTF32 * pUtf32 = static_cast<const UTF32 *> (a_pInputData);
retval = ConvertUTF32toUTF8(
&pUtf32, pUtf32 + uInputLen,
&pUtf8, pUtf8 + a_uOutputDataSize,
lenientConversion);
}
else if (sizeof(wchar_t) == sizeof(UTF16)) {
- const UTF16 * pUtf16 = (const UTF16 *) a_pInputData;
+ const UTF16 * pUtf16 = static_cast<const UTF16 *> (a_pInputData);
retval = ConvertUTF16toUTF8(
&pUtf16, pUtf16 + uInputLen,
&pUtf8, pUtf8 + a_uOutputDataSize,
@@ -2968,7 +2968,7 @@ public: else {
size_t retval = wcstombs(a_pOutputData,
a_pInputData, a_uOutputDataSize);
- return retval != (size_t) -1;
+ return retval != static_cast<size_t> (-1);
}
}
};
|