summaryrefslogtreecommitdiffstats
path: root/Objects/classobject.c
diff options
context:
space:
mode:
Diffstat (limited to 'Objects/classobject.c')
-rw-r--r--Objects/classobject.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/Objects/classobject.c b/Objects/classobject.c
index 9cfdf0e..79656f5 100644
--- a/Objects/classobject.c
+++ b/Objects/classobject.c
@@ -1136,9 +1136,9 @@ instance_ass_item(PyInstanceObject *inst, Py_ssize_t i, PyObject *item)
if (func == NULL)
return -1;
if (item == NULL)
- arg = Py_BuildValue("i", i);
+ arg = PyInt_FromSsize_t(i);
else
- arg = Py_BuildValue("(iO)", i, item);
+ arg = Py_BuildValue("(nO)", i, item);
if (arg == NULL) {
Py_DECREF(func);
return -1;