summaryrefslogtreecommitdiff
path: root/Include/descrobject.h
diff options
context:
space:
mode:
authorGuido van Rossum <guido@python.org>2001-09-20 20:46:19 +0000
committerGuido van Rossum <guido@python.org>2001-09-20 20:46:19 +0000
commitfadc3568b2349da11025bc82a6573fe387a8c237 (patch)
tree94f30f54e9973755c433dc199f409c53993a7bc0 /Include/descrobject.h
parent63efa2fa5cc2bd4a440da8c0b1a7e0dff703d0c3 (diff)
downloadcpython-fadc3568b2349da11025bc82a6573fe387a8c237.tar.gz
Add optional docstrings to member descriptors. For backwards
compatibility, this required all places where an array of "struct memberlist" structures was declared that is referenced from a type's tp_members slot to change the type of the structure to PyMemberDef; "struct memberlist" is now only used by old code that still calls PyMember_Get/Set. The code in PyObject_GenericGetAttr/SetAttr now calls the new APIs PyMember_GetOne/SetOne, which take a PyMemberDef argument. As examples, I added actual docstrings to the attributes of a few types: file, complex, instance method, super, and xxsubtype.spamlist. Also converted the symtable to new style getattr.
Diffstat (limited to 'Include/descrobject.h')
-rw-r--r--Include/descrobject.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/Include/descrobject.h b/Include/descrobject.h
index a86831051f..3d581818f5 100644
--- a/Include/descrobject.h
+++ b/Include/descrobject.h
@@ -21,7 +21,7 @@ struct wrapperbase {
extern DL_IMPORT(PyObject *) PyDescr_NewMethod(PyTypeObject *, PyMethodDef *);
extern DL_IMPORT(PyObject *) PyDescr_NewMember(PyTypeObject *,
- struct memberlist *);
+ struct PyMemberDef *);
extern DL_IMPORT(PyObject *) PyDescr_NewGetSet(PyTypeObject *,
struct getsetlist *);
extern DL_IMPORT(PyObject *) PyDescr_NewWrapper(PyTypeObject *,