There was an error while loading. Please reload this page.
2 parents 1b5c76a + 949f331 commit f03572dCopy full SHA for f03572d
1 file changed
Objects/classobject.c
@@ -219,14 +219,15 @@ method_repr(PyMethodObject *a)
219
{
220
PyObject *self = a->im_self;
221
PyObject *func = a->im_func;
222
- PyObject *klass = (PyObject*)Py_TYPE(self);
+ PyObject *klass;
223
PyObject *funcname = NULL ,*klassname = NULL, *result = NULL;
224
char *defname = "?";
225
226
if (self == NULL) {
227
PyErr_BadInternalCall();
228
return NULL;
229
}
230
+ klass = (PyObject*)Py_TYPE(self);
231
232
funcname = _PyObject_GetAttrId(func, &PyId___name__);
233
if (funcname == NULL) {
0 commit comments