diff options
Diffstat (limited to 'Include/descrobject.h')
-rw-r--r-- | Include/descrobject.h | 14 |
1 files changed, 8 insertions, 6 deletions
diff --git a/Include/descrobject.h b/Include/descrobject.h index f06b421..7c42808 100644 --- a/Include/descrobject.h +++ b/Include/descrobject.h @@ -37,15 +37,17 @@ struct wrapperbase { /* Various kinds of descriptor objects */ -#define PyDescr_COMMON \ - PyObject_HEAD \ - PyTypeObject *d_type; \ - PyObject *d_name - typedef struct { - PyDescr_COMMON; + PyObject_HEAD + PyTypeObject *d_type; + PyObject *d_name; } PyDescrObject; +#define PyDescr_COMMON PyDescrObject d_common + +#define PyDescr_TYPE(x) (((PyDescrObject *)(x))->d_type) +#define PyDescr_NAME(x) (((PyDescrObject *)(x))->d_name) + typedef struct { PyDescr_COMMON; PyMethodDef *d_method; |