Py3: fix warning: missing field 'tp_print' initializer [-Wmissing-field-initializers]

This warning is only specific to Py3.8. See https://docs.python.org/3/c-api/typeobj.html
This commit is contained in:
wmayer
2020-10-15 10:35:47 +02:00
parent 71236cbc29
commit bc6fefe3a0

View File

@@ -366,8 +366,12 @@ PyTypeObject @self.export.Name@::Type = {
#if PY_MAJOR_VERSION >= 3
,0 /*tp_finalize */
#endif
#if PY_VERSION_HEX >= 0x03080000
#if PY_VERSION_HEX >= 0x03090000
,0 /*tp_vectorcall */
#elif PY_VERSION_HEX >= 0x03080000
,0 /*tp_vectorcall */
/* bpo-37250: kept for backwards compatibility in CPython 3.8 only */
,0 /*tp_print */
#endif
};