mirror of
https://github.com/python/cpython.git
synced 2025-08-31 14:07:50 +00:00
Merge ssize_t branch.
This commit is contained in:
parent
4482929734
commit
18e165558b
102 changed files with 2659 additions and 1677 deletions
|
@ -680,7 +680,7 @@ complex_subtype_from_string(PyTypeObject *type, PyObject *v)
|
|||
#ifdef Py_USING_UNICODE
|
||||
char s_buffer[256];
|
||||
#endif
|
||||
int len;
|
||||
Py_ssize_t len;
|
||||
|
||||
if (PyString_Check(v)) {
|
||||
s = PyString_AS_STRING(v);
|
||||
|
@ -699,7 +699,7 @@ complex_subtype_from_string(PyTypeObject *type, PyObject *v)
|
|||
NULL))
|
||||
return NULL;
|
||||
s = s_buffer;
|
||||
len = (int)strlen(s);
|
||||
len = strlen(s);
|
||||
}
|
||||
#endif
|
||||
else if (PyObject_AsCharBuffer(v, &s, &len)) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue