summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorNeal Norwitz <nnorwitz@gmail.com>2002-08-13 19:01:38 (GMT)
committerNeal Norwitz <nnorwitz@gmail.com>2002-08-13 19:01:38 (GMT)
commitd47714a727928d754f8eded9546b3b294dadf225 (patch)
tree319cb7424e64bff82796f4d97ad76bf6d5f4c436
parent8b056da6c8dff3bd2ac79c88690e738c44b80a17 (diff)
downloadcpython-d47714a727928d754f8eded9546b3b294dadf225.zip
cpython-d47714a727928d754f8eded9546b3b294dadf225.tar.gz
cpython-d47714a727928d754f8eded9546b3b294dadf225.tar.bz2
Allow docstrings to be removed during compilation for *SLOT macro and friends
-rw-r--r--Objects/typeobject.c8
1 files changed, 5 insertions, 3 deletions
diff --git a/Objects/typeobject.c b/Objects/typeobject.c
index 809e006..812c66f 100644
--- a/Objects/typeobject.c
+++ b/Objects/typeobject.c
@@ -3850,12 +3850,14 @@ typedef struct wrapperbase slotdef;
#undef RBINSLOT
#define TPSLOT(NAME, SLOT, FUNCTION, WRAPPER, DOC) \
- {NAME, offsetof(PyTypeObject, SLOT), (void *)(FUNCTION), WRAPPER, DOC}
+ {NAME, offsetof(PyTypeObject, SLOT), (void *)(FUNCTION), WRAPPER, \
+ PyDoc_STR(DOC)}
#define FLSLOT(NAME, SLOT, FUNCTION, WRAPPER, DOC, FLAGS) \
{NAME, offsetof(PyTypeObject, SLOT), (void *)(FUNCTION), WRAPPER, \
- DOC, FLAGS}
+ PyDoc_STR(DOC), FLAGS}
#define ETSLOT(NAME, SLOT, FUNCTION, WRAPPER, DOC) \
- {NAME, offsetof(etype, SLOT), (void *)(FUNCTION), WRAPPER, DOC}
+ {NAME, offsetof(etype, SLOT), (void *)(FUNCTION), WRAPPER, \
+ PyDoc_STR(DOC)}
#define SQSLOT(NAME, SLOT, FUNCTION, WRAPPER, DOC) \
ETSLOT(NAME, as_sequence.SLOT, FUNCTION, WRAPPER, DOC)
#define MPSLOT(NAME, SLOT, FUNCTION, WRAPPER, DOC) \