X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/8a9d5e5a7321ab71ad690ec98f374bf2b28148b9..81c9effa8462662263c3b4eac2cfae1ef5caae2c:/src/common/string.cpp diff --git a/src/common/string.cpp b/src/common/string.cpp index c8ebc830cd..d8a1d812b2 100644 --- a/src/common/string.cpp +++ b/src/common/string.cpp @@ -46,13 +46,9 @@ #include #endif -#ifdef WXSTRING_IS_WXOBJECT - IMPLEMENT_DYNAMIC_CLASS(wxString, wxObject) -#endif //WXSTRING_IS_WXOBJECT - #if wxUSE_UNICODE -#undef wxUSE_EXPERIMENTAL_PRINTF -#define wxUSE_EXPERIMENTAL_PRINTF 1 + #undef wxUSE_EXPERIMENTAL_PRINTF + #define wxUSE_EXPERIMENTAL_PRINTF 1 #endif // allocating extra space for each string consumes more memory but speeds up @@ -1101,6 +1097,7 @@ int wxString::Find(const wxChar *pszSub) const bool wxString::ToLong(long *val, int base) const { wxCHECK_MSG( val, FALSE, _T("NULL pointer in wxString::ToLong") ); + wxASSERT_MSG( !base || (base > 1 && base <= 36), _T("invalid base") ); const wxChar *start = c_str(); wxChar *end; @@ -1114,6 +1111,7 @@ bool wxString::ToLong(long *val, int base) const bool wxString::ToULong(unsigned long *val, int base) const { wxCHECK_MSG( val, FALSE, _T("NULL pointer in wxString::ToULong") ); + wxASSERT_MSG( !base || (base > 1 && base <= 36), _T("invalid base") ); const wxChar *start = c_str(); wxChar *end;