consistently use Py_TYPE, Py_REFCNT, and correct initializer macros (#3563)
This no-op change makes 2.7 more consistent with 3.x to ease comparison and backports.
diff --git a/Modules/_testcapimodule.c b/Modules/_testcapimodule.c
index ecc473c..7691b51 100644
--- a/Modules/_testcapimodule.c
+++ b/Modules/_testcapimodule.c
@@ -187,8 +187,7 @@
* PyType_Ready if it hasn't already been called
*/
static PyTypeObject _HashInheritanceTester_Type = {
- PyObject_HEAD_INIT(NULL)
- 0, /* Number of items for varobject */
+ PyVarObject_HEAD_INIT(NULL, 0)
"hashinheritancetester", /* Name of this type */
sizeof(PyObject), /* Basic object size */
0, /* Item size for varobject */
@@ -315,8 +314,7 @@
};
static PyTypeObject _MemoryViewTester_Type = {
- PyObject_HEAD_INIT(NULL)
- 0, /* Number of items for varobject */
+ PyVarObject_HEAD_INIT(NULL, 0)
"memoryviewtester", /* Name of this type */
sizeof(PyObject), /* Basic object size */
0, /* Item size for varobject */