[3.7] Fix misleading mentions of tp_size in comments. (GH-9136)
Many type object initializations labeled a field "tp_size" in the
comment, but the name of that field is tp_basicsize..
(cherry picked from commit 0e0bc4e221f592f305d335faf5f8046484eb9238)
Co-authored-by: Peter Eisentraut <peter@eisentraut.org>
diff --git a/Modules/_threadmodule.c b/Modules/_threadmodule.c
index f594bda..16d3191 100644
--- a/Modules/_threadmodule.c
+++ b/Modules/_threadmodule.c
@@ -226,7 +226,7 @@
static PyTypeObject Locktype = {
PyVarObject_HEAD_INIT(&PyType_Type, 0)
"_thread.lock", /*tp_name*/
- sizeof(lockobject), /*tp_size*/
+ sizeof(lockobject), /*tp_basicsize*/
0, /*tp_itemsize*/
/* methods */
(destructor)lock_dealloc, /*tp_dealloc*/
@@ -487,7 +487,7 @@
static PyTypeObject RLocktype = {
PyVarObject_HEAD_INIT(&PyType_Type, 0)
"_thread.RLock", /*tp_name*/
- sizeof(rlockobject), /*tp_size*/
+ sizeof(rlockobject), /*tp_basicsize*/
0, /*tp_itemsize*/
/* methods */
(destructor)rlock_dealloc, /*tp_dealloc*/