diff options
Diffstat (limited to 'Objects/stringlib/ucs4lib.h')
-rw-r--r-- | Objects/stringlib/ucs4lib.h | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/Objects/stringlib/ucs4lib.h b/Objects/stringlib/ucs4lib.h index 57344f2..def4ca5 100644 --- a/Objects/stringlib/ucs4lib.h +++ b/Objects/stringlib/ucs4lib.h @@ -21,6 +21,10 @@ #define STRINGLIB_CHECK PyUnicode_Check #define STRINGLIB_CHECK_EXACT PyUnicode_CheckExact #define STRINGLIB_MUTABLE 0 +#if SIZEOF_WCHAR_T == 4 +#define STRINGLIB_FAST_MEMCHR(s, c, n) \ + (Py_UCS4 *)wmemchr((const wchar_t *)(s), c, n) +#endif #define STRINGLIB_TOSTR PyObject_Str #define STRINGLIB_TOASCII PyObject_ASCII |