args = PyTuple_Pack(1, dd->default_factory);
if (args == NULL)
return NULL;
- items = _PyObject_CallMethodId((PyObject *)dd, &PyId_items, "()");
+ items = _PyObject_CallMethodId((PyObject *)dd, &PyId_items, NULL);
if (items == NULL) {
Py_DECREF(args);
return NULL;
if (time != NULL) {
_Py_IDENTIFIER(time);
- result = _PyObject_CallMethodId(time, &PyId_time, "()");
+ result = _PyObject_CallMethodId(time, &PyId_time, NULL);
Py_DECREF(time);
}
return result;
static PyObject *
date_str(PyDateTime_Date *self)
{
- return _PyObject_CallMethodId((PyObject *)self, &PyId_isoformat, "()");
+ return _PyObject_CallMethodId((PyObject *)self, &PyId_isoformat, NULL);
}
&format))
return NULL;
- tuple = _PyObject_CallMethodId((PyObject *)self, &PyId_timetuple, "()");
+ tuple = _PyObject_CallMethodId((PyObject *)self, &PyId_timetuple, NULL);
if (tuple == NULL)
return NULL;
result = wrap_strftime((PyObject *)self, format, tuple,
static PyObject *
time_str(PyDateTime_Time *self)
{
- return _PyObject_CallMethodId((PyObject *)self, &PyId_isoformat, "()");
+ return _PyObject_CallMethodId((PyObject *)self, &PyId_isoformat, NULL);
}
static PyObject *
} else {
_Py_IDENTIFIER(items);
- items = _PyObject_CallMethodId(obj, &PyId_items, "()");
+ items = _PyObject_CallMethodId(obj, &PyId_items, NULL);
if (items == NULL)
goto error;
iter = PyObject_GetIter(items);
FUNCNAME(PyObject *self) \
{ \
_Py_static_string(id, OPSTR); \
- return call_method(self, &id, "()"); \
+ return call_method(self, &id, NULL); \
}
#define SLOT1(FUNCNAME, OPSTR, ARG1TYPE, ARGCODES) \
static Py_ssize_t
slot_sq_length(PyObject *self)
{
- PyObject *res = call_method(self, &PyId___len__, "()");
+ PyObject *res = call_method(self, &PyId___len__, NULL);
Py_ssize_t len;
if (res == NULL)
slot_nb_index(PyObject *self)
{
_Py_IDENTIFIER(__index__);
- return call_method(self, &PyId___index__, "()");
+ return call_method(self, &PyId___index__, NULL);
}
slot_tp_iternext(PyObject *self)
{
_Py_IDENTIFIER(__next__);
- return call_method(self, &PyId___next__, "()");
+ return call_method(self, &PyId___next__, NULL);
}
static PyObject *
int n = countformat(f, '\0');
va_list lva;
- Py_VA_COPY(lva, va);
+ Py_VA_COPY(lva, va);
if (n < 0)
return NULL;