Mercurial > cpython-lru_cache-weakref
diff Objects/typeobject.c @ 20241:aff6fcd26c15 legacy-trunk
type_new(): cast PyObject_MALLOC's result to char*, for clarity.
| author | Tim Peters <tim.peters@gmail.com> |
|---|---|
| date | Thu, 04 Oct 2001 05:43:02 +0000 |
| parents | 2745c3dc24af |
| children | 6152f82ea823 |
line wrap: on
line diff
--- a/Objects/typeobject.c Thu Oct 04 05:36:56 2001 +0000 +++ b/Objects/typeobject.c Thu Oct 04 05:43:02 2001 +0000 @@ -909,7 +909,7 @@ PyObject *doc = PyDict_GetItemString(dict, "__doc__"); if (doc != NULL && PyString_Check(doc)) { const size_t n = (size_t)PyString_GET_SIZE(doc); - type->tp_doc = PyObject_MALLOC(n+1); + type->tp_doc = (char *)PyObject_MALLOC(n+1); if (type->tp_doc == NULL) { Py_DECREF(type); return NULL;
