diff options
Diffstat (limited to 'Objects')
-rw-r--r-- | Objects/methodobject.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/Objects/methodobject.c b/Objects/methodobject.c index 5f5d595..d7dc280 100644 --- a/Objects/methodobject.c +++ b/Objects/methodobject.c @@ -135,7 +135,7 @@ meth_get__doc__(PyCFunctionObject *m, void *closure) const char *doc = m->m_ml->ml_doc; if (doc != NULL) - return PyString_FromString(doc); + return PyUnicode_FromString(doc); Py_INCREF(Py_None); return Py_None; } @@ -284,7 +284,7 @@ Py_FindMethodInChain(PyMethodChain *chain, PyObject *self, const char *name) if (strcmp(name, "__doc__") == 0) { const char *doc = self->ob_type->tp_doc; if (doc != NULL) - return PyString_FromString(doc); + return PyUnicode_FromString(doc); } } while (chain != NULL) { |