Show More
@@ -930,6 +930,7 b' static int index_slice_del(indexObject *' | |||
|
930 | 930 | { |
|
931 | 931 | Py_ssize_t start, stop, step, slicelength; |
|
932 | 932 | Py_ssize_t length = index_length(self); |
|
933 | int ret = 0; | |
|
933 | 934 | |
|
934 | 935 | if (PySlice_GetIndicesEx((PySliceObject*)item, length, |
|
935 | 936 | &start, &stop, &step, &slicelength) < 0) |
@@ -975,7 +976,9 b' static int index_slice_del(indexObject *' | |||
|
975 | 976 | self->ntrev = (int)start; |
|
976 | 977 | } |
|
977 | 978 | self->length = start + 1; |
|
978 | return 0; | |
|
979 | if (start < self->raw_length) | |
|
980 | self->raw_length = start; | |
|
981 | goto done; | |
|
979 | 982 | } |
|
980 | 983 | |
|
981 | 984 | if (self->nt) { |
@@ -983,10 +986,11 b' static int index_slice_del(indexObject *' | |||
|
983 | 986 | if (self->ntrev > start) |
|
984 | 987 | self->ntrev = (int)start; |
|
985 | 988 | } |
|
986 |
|
|
|
987 |
|
|
|
988 | PyList_GET_SIZE(self->added), NULL) | |
|
989 | : 0; | |
|
989 | if (self->added) | |
|
990 | ret = PyList_SetSlice(self->added, start - self->length + 1, | |
|
991 | PyList_GET_SIZE(self->added), NULL); | |
|
992 | done: | |
|
993 | return ret; | |
|
990 | 994 | } |
|
991 | 995 | |
|
992 | 996 | /* |
General Comments 0
You need to be logged in to leave comments.
Login now