{
_Py_IDENTIFIER(find_class);
- return _PyObject_CallMethodId((PyObject *)self, &PyId_find_class, "OO",
- module_name, global_name);
+ return _PyObject_CallMethodIdObjArgs((PyObject *)self, &PyId_find_class,
+ module_name, global_name, NULL);
}
static Py_ssize_t
else {
_Py_IDENTIFIER(__new__);
- result = _PyObject_CallMethodId(cls, &PyId___new__, "O", cls);
+ result = _PyObject_CallMethodIdObjArgs(cls, &PyId___new__, cls, NULL);
}
return result;
}
bytes = PyBytes_FromStringAndSize(ptr, size);
if (bytes == NULL)
return NULL;
- res = _PyObject_CallMethodId(f, &PyId_write, "O", bytes);
+ res = _PyObject_CallMethodIdObjArgs(f, &PyId_write, bytes, NULL);
Py_DECREF(bytes);
if (res == NULL)
return NULL;
if (str == NULL)
return -1;
- wr = _PyObject_CallMethodId(self->stream, &PyId_write, "O", str);
+ wr = _PyObject_CallMethodIdObjArgs(self->stream, &PyId_write, str, NULL);
Py_DECREF(str);
if (wr == NULL)
return -1;
if (PyBytes_Size(pwrt) > 0) {
PyObject *wr;
- wr = _PyObject_CallMethodId(self->stream, &PyId_write, "O", pwrt);
+ wr = _PyObject_CallMethodIdObjArgs(self->stream, &PyId_write, pwrt);
if (wr == NULL) {
Py_DECREF(pwrt);
return NULL;
if (obj == Py_None)
return 1;
- result = _PyObject_CallMethodId(obj, &PyId_match, "O", arg);
+ result = _PyObject_CallMethodIdObjArgs(obj, &PyId_match, arg, NULL);
if (result == NULL)
return -1;
Py_INCREF(imp);
}
- reloaded_module = _PyObject_CallMethodId(imp, &PyId_reload, "O", m);
+ reloaded_module = _PyObject_CallMethodIdObjArgs(imp, &PyId_reload, m, NULL);
Py_DECREF(imp);
return reloaded_module;
}
s = PyMarshal_WriteObjectToString(x, version);
if (s == NULL)
return NULL;
- res = _PyObject_CallMethodId(f, &PyId_write, "O", s);
+ res = _PyObject_CallMethodIdObjArgs(f, &PyId_write, s, NULL);
Py_DECREF(s);
return res;
}