Make module docstrings unicode objects.
This commit is contained in:
parent
427dbff8f0
commit
6e8fcae38f
|
@ -92,7 +92,7 @@ Py_InitModule4(const char *name, PyMethodDef *methods, const char *doc,
|
|||
Py_DECREF(n);
|
||||
}
|
||||
if (doc != NULL) {
|
||||
v = PyString_FromString(doc);
|
||||
v = PyUnicode_FromString(doc);
|
||||
if (v == NULL || PyDict_SetItemString(d, "__doc__", v) != 0) {
|
||||
Py_XDECREF(v);
|
||||
return NULL;
|
||||
|
|
Loading…
Reference in New Issue