mirror of
https://github.com/python/cpython.git
synced 2025-08-31 05:58:33 +00:00
Merge branches/pep-0384.
This commit is contained in:
parent
c4df784514
commit
4d0d471a80
102 changed files with 2835 additions and 75 deletions
|
@ -2397,7 +2397,7 @@ list_subscript(PyListObject* self, PyObject* item)
|
|||
PyObject* it;
|
||||
PyObject **src, **dest;
|
||||
|
||||
if (PySlice_GetIndicesEx((PySliceObject*)item, Py_SIZE(self),
|
||||
if (PySlice_GetIndicesEx(item, Py_SIZE(self),
|
||||
&start, &stop, &step, &slicelength) < 0) {
|
||||
return NULL;
|
||||
}
|
||||
|
@ -2446,7 +2446,7 @@ list_ass_subscript(PyListObject* self, PyObject* item, PyObject* value)
|
|||
else if (PySlice_Check(item)) {
|
||||
Py_ssize_t start, stop, step, slicelength;
|
||||
|
||||
if (PySlice_GetIndicesEx((PySliceObject*)item, Py_SIZE(self),
|
||||
if (PySlice_GetIndicesEx(item, Py_SIZE(self),
|
||||
&start, &stop, &step, &slicelength) < 0) {
|
||||
return -1;
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue