diff options
Diffstat (limited to 'Modules/xxsubtype.c')
-rw-r--r-- | Modules/xxsubtype.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/Modules/xxsubtype.c b/Modules/xxsubtype.c index 9e4a3d66ef4..63b22268c59 100644 --- a/Modules/xxsubtype.c +++ b/Modules/xxsubtype.c @@ -1,5 +1,6 @@ #include "Python.h" -#include "structmember.h" // PyMemberDef +#include <stddef.h> // offsetof() + PyDoc_STRVAR(xxsubtype__doc__, "xxsubtype is an example module showing how to subtype builtin types from C.\n" @@ -181,7 +182,7 @@ spamdict_init(spamdictobject *self, PyObject *args, PyObject *kwds) } static PyMemberDef spamdict_members[] = { - {"state", T_INT, offsetof(spamdictobject, state), READONLY, + {"state", Py_T_INT, offsetof(spamdictobject, state), Py_READONLY, PyDoc_STR("an int variable for demonstration purposes")}, {0} }; |