added code for optimized handling of UTF-8 locales: some string operations are more efficient under it and it's possible to completely compile-out support for other locales if the target system is known to only use UTF-8 locales

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@45782 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Václav Slavík
2007-05-03 11:05:04 +00:00
parent d1f6e2cfe2
commit 111d99489d
10 changed files with 329 additions and 110 deletions

View File

@@ -65,7 +65,8 @@ struct WXDLLIMPEXP_BASE wxStringOperationsWchar
struct WXDLLIMPEXP_BASE wxStringOperationsUtf8
{
// checks correctness of UTF-8 sequence
static bool IsValidUtf8String(const char *c);
static bool IsValidUtf8String(const char *c,
size_t len = wxStringImpl::npos);
#ifdef __WXDEBUG__
static bool IsValidUtf8LeadByte(unsigned char c);
#endif