Home
last modified time | relevance | path

Searched refs:slicelen (Results 1 – 5 of 5) sorted by relevance

/external/python/cpython2/Modules/
Dmmapmodule.c785 Py_ssize_t start, stop, step, slicelen; in mmap_subscript() local
788 &start, &stop, &step, &slicelen) < 0) { in mmap_subscript()
792 if (slicelen <= 0) in mmap_subscript()
796 slicelen); in mmap_subscript()
798 char *result_buf = (char *)PyMem_Malloc(slicelen); in mmap_subscript()
804 for (cur = start, i = 0; i < slicelen; in mmap_subscript()
809 slicelen); in mmap_subscript()
940 Py_ssize_t start, stop, step, slicelen; in mmap_ass_subscript() local
944 &step, &slicelen) < 0) { in mmap_ass_subscript()
957 if (PyString_Size(value) != slicelen) { in mmap_ass_subscript()
[all …]
D_elementtree.c1325 Py_ssize_t start, stop, step, slicelen, cur, i; local
1333 &start, &stop, &step, &slicelen) < 0) {
1337 if (slicelen <= 0)
1340 list = PyList_New(slicelen);
1344 for (cur = start, i = 0; i < slicelen;
1382 Py_ssize_t start, stop, step, slicelen, newlen, cur, i; local
1392 &start, &stop, &step, &slicelen) < 0) {
1395 assert(slicelen <= self->extra->length);
1411 if (step != 1 && newlen != slicelen)
1418 (int)newlen, (int)slicelen
[all …]
/external/python/cpython2/Objects/
Dstructseq.c114 Py_ssize_t start, stop, step, slicelen, cur, i; in structseq_subscript() local
119 &step, &slicelen) < 0) { in structseq_subscript()
122 if (slicelen <= 0) in structseq_subscript()
124 result = PyTuple_New(slicelen); in structseq_subscript()
127 for (cur = start, i = 0; i < slicelen; in structseq_subscript()
Dbytearrayobject.c589 Py_ssize_t start, stop, step, slicelen, needed; in bytearray_ass_subscript() local
611 slicelen = 1; in bytearray_ass_subscript()
624 &start, &stop, &step, &slicelen) < 0) { in bytearray_ass_subscript()
663 if (slicelen != needed) { in bytearray_ass_subscript()
666 if (slicelen > needed) { in bytearray_ass_subscript()
677 Py_SIZE(self) + needed - slicelen) < 0) in bytearray_ass_subscript()
679 if (slicelen < needed) { in bytearray_ass_subscript()
706 start = stop + step * (slicelen - 1) - 1; in bytearray_ass_subscript()
710 i < slicelen; cur += step, i++) { in bytearray_ass_subscript()
720 cur = start + slicelen*step; in bytearray_ass_subscript()
[all …]
/external/python/cpython2/Modules/_ctypes/
D_ctypes.c4435 Py_ssize_t start, stop, step, slicelen, cur, i; in Array_subscript() local
4439 &step, &slicelen) < 0) { in Array_subscript()
4454 if (slicelen <= 0) in Array_subscript()
4458 slicelen); in Array_subscript()
4460 dest = (char *)PyMem_Malloc(slicelen); in Array_subscript()
4465 for (cur = start, i = 0; i < slicelen; in Array_subscript()
4470 np = PyString_FromStringAndSize(dest, slicelen); in Array_subscript()
4479 if (slicelen <= 0) in Array_subscript()
4483 slicelen); in Array_subscript()
4486 dest = PyMem_New(wchar_t, slicelen); in Array_subscript()
[all …]