Commit 8c42a284 authored by Victor Stinner's avatar Victor Stinner

Disable unicode_resize() optimization on Windows (16-bit wchar_t)

parent 9e26e819
...@@ -1185,6 +1185,10 @@ static int ...@@ -1185,6 +1185,10 @@ static int
unicode_resizable(PyObject *unicode) unicode_resizable(PyObject *unicode)
{ {
Py_ssize_t len; Py_ssize_t len;
#if SIZEOF_WCHAR_T == 2
/* FIXME: unicode_resize() is buggy on Windows */
return 0;
#endif
if (Py_REFCNT(unicode) != 1) if (Py_REFCNT(unicode) != 1)
return 0; return 0;
if (PyUnicode_CHECK_INTERNED(unicode)) if (PyUnicode_CHECK_INTERNED(unicode))
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment