Message400396
Is it worth removing the len field as well and lazily using get_len_of_range() as needed?
Then the hot function can look something like:
static PyObject *
rangeiter_next(rangeiterobject *r)
{
long result = r->start
if (result < r->stop) {
r->start += r->step;
return PyLong_FromLong(result);
}
return NULL;
} |
|
Date |
User |
Action |
Args |
2021-08-27 05:09:59 | Dennis Sweeney | set | recipients:
+ Dennis Sweeney, rhettinger, lukasz.langa, serhiy.storchaka |
2021-08-27 05:09:59 | Dennis Sweeney | set | messageid: <1630040999.13.0.421010922122.issue45026@roundup.psfhosted.org> |
2021-08-27 05:09:59 | Dennis Sweeney | link | issue45026 messages |
2021-08-27 05:09:59 | Dennis Sweeney | create | |
|