Base: Initialize tp_versions_used in PyTypeObject (3.13)
This field is undocumented, but exists in the source code for 3.13 (see https://github.com/python/cpython/blob/3.13/Include/cpython/object.h#L232) and gives a compiler warning if left uninitialized.
This commit is contained in:
committed by
Kacper Donat
parent
d3f617bb4b
commit
ebc0dc165d
@@ -169,7 +169,9 @@ static PyTypeObject PyBaseProxyType = {
|
||||
#if PY_VERSION_HEX >= 0x030c0000
|
||||
,0 /*tp_watched */
|
||||
#endif
|
||||
|
||||
#if PY_VERSION_HEX >= 0x030d0000
|
||||
,0 /*tp_versions_used*/
|
||||
#endif
|
||||
};
|
||||
|
||||
PyTypeObject PyObjectBase::Type = {
|
||||
@@ -228,6 +230,9 @@ PyTypeObject PyObjectBase::Type = {
|
||||
#if PY_VERSION_HEX >= 0x030c0000
|
||||
,0 /*tp_watched */
|
||||
#endif
|
||||
#if PY_VERSION_HEX >= 0x030d0000
|
||||
,0 /*tp_versions_used*/
|
||||
#endif
|
||||
};
|
||||
|
||||
#if defined(__clang__)
|
||||
|
||||
Reference in New Issue
Block a user