summaryrefslogtreecommitdiffstats
path: root/Python
diff options
context:
space:
mode:
Diffstat (limited to 'Python')
-rw-r--r--Python/bltinmodule.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/Python/bltinmodule.c b/Python/bltinmodule.c
index dca8555..3e5f4eb 100644
--- a/Python/bltinmodule.c
+++ b/Python/bltinmodule.c
@@ -221,7 +221,7 @@ builtin_filter(PyObject *self, PyObject *args)
goto Fail_arg;
/* Guess a result list size. */
- len = PyObject_Size(seq);
+ len = _PyObject_LengthCue(seq);
if (len < 0) {
if (!PyErr_ExceptionMatches(PyExc_TypeError) &&
!PyErr_ExceptionMatches(PyExc_AttributeError)) {
@@ -873,7 +873,7 @@ builtin_map(PyObject *self, PyObject *args)
}
/* Update len. */
- curlen = PyObject_Size(curseq);
+ curlen = _PyObject_LengthCue(curseq);
if (curlen < 0) {
if (!PyErr_ExceptionMatches(PyExc_TypeError) &&
!PyErr_ExceptionMatches(PyExc_AttributeError)) {
@@ -2108,7 +2108,7 @@ builtin_zip(PyObject *self, PyObject *args)
len = -1; /* unknown */
for (i = 0; i < itemsize; ++i) {
PyObject *item = PyTuple_GET_ITEM(args, i);
- int thislen = PyObject_Size(item);
+ int thislen = _PyObject_LengthCue(item);
if (thislen < 0) {
if (!PyErr_ExceptionMatches(PyExc_TypeError) &&
!PyErr_ExceptionMatches(PyExc_AttributeError)) {