Commit e0e89f79 authored by Martin v. Löwis's avatar Martin v. Löwis

Revert 42400.

parent 2c95cc6d
......@@ -246,15 +246,15 @@ buffer_repr(PyBufferObject *self)
return PyString_FromFormat("<%s buffer ptr %p, size %zd at %p>",
status,
self->b_ptr,
(long)self->b_size,
self->b_size,
self);
else
return PyString_FromFormat(
"<%s buffer for %p, size %zd, offset %zd at %p>",
status,
self->b_base,
(long)self->b_size,
(long)self->b_offset,
self->b_size,
self->b_offset,
self);
}
......
......@@ -1149,7 +1149,7 @@ PyDict_MergeFromSeq2(PyObject *d, PyObject *seq2, int override)
PyErr_Format(PyExc_ValueError,
"dictionary update sequence element #%d "
"has length %zd; 2 is required",
i, (long)n);
i, n);
goto Fail;
}
......
......@@ -251,7 +251,7 @@ func_set_code(PyFunctionObject *op, PyObject *value)
"%s() requires a code object with %zd free vars,"
" not %zd",
PyString_AsString(op->func_name),
(long)nclosure, (long)nfree);
nclosure, nfree);
return -1;
}
tmp = op->func_code;
......@@ -403,7 +403,7 @@ func_new(PyTypeObject* type, PyObject* args, PyObject* kw)
return PyErr_Format(PyExc_ValueError,
"%s requires closure of length %zd, not %zd",
PyString_AS_STRING(code->co_name),
(long)nfree, (long)nclosure);
nfree, nclosure);
if (nclosure) {
Py_ssize_t i;
for (i = 0; i < nclosure; i++) {
......
......@@ -2600,8 +2600,8 @@ list_ass_subscript(PyListObject* self, PyObject* item, PyObject* value)
if (PySequence_Fast_GET_SIZE(seq) != slicelength) {
PyErr_Format(PyExc_ValueError,
"attempt to assign sequence of size %zd to extended slice of size %zd",
(long)PySequence_Fast_GET_SIZE(seq),
(long)slicelength);
PySequence_Fast_GET_SIZE(seq),
slicelength);
Py_DECREF(seq);
return -1;
}
......
......@@ -126,7 +126,7 @@ structseq_new(PyTypeObject *type, PyObject *args, PyObject *kwds)
if (len < min_len) {
PyErr_Format(PyExc_TypeError,
"%.500s() takes an at least %zd-sequence (%zd-sequence given)",
type->tp_name, (long)min_len, (long)len);
type->tp_name, min_len, len);
Py_DECREF(arg);
return NULL;
}
......@@ -134,7 +134,7 @@ structseq_new(PyTypeObject *type, PyObject *args, PyObject *kwds)
if (len > max_len) {
PyErr_Format(PyExc_TypeError,
"%.500s() takes an at most %zd-sequence (%zd-sequence given)",
type->tp_name, (long)max_len, (long)len);
type->tp_name, max_len, len);
Py_DECREF(arg);
return NULL;
}
......@@ -143,7 +143,7 @@ structseq_new(PyTypeObject *type, PyObject *args, PyObject *kwds)
if (len != min_len) {
PyErr_Format(PyExc_TypeError,
"%.500s() takes a %zd-sequence (%zd-sequence given)",
type->tp_name, (long)min_len, (long)len);
type->tp_name, min_len, len);
Py_DECREF(arg);
return NULL;
}
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment