@@ -387,27 +387,27 @@ Accessing attributes of extension types
387387 Structure which describes an attribute of a type which corresponds to a C
388388 struct member. Its fields are:
389389
390- +------------------+---------------+-------------------------------+
391- | Field | C Type | Meaning |
392- +==================+===============+===============================+
393- | :attr:`name` | const char \* | name of the member |
394- +------------------+---------------+-------------------------------+
395- | :attr:`!type` | int | the type of the member in the |
396- | | | C struct |
397- +------------------+---------------+-------------------------------+
398- | :attr:`offset` | Py_ssize_t | the offset in bytes that the |
399- | | | member is located on the |
400- | | | type' s object struct |
401- +------------------+---------------+-------------------------------+
402- | :attr:`flags` | int | flag bits indicating if the |
403- | | | field should be read-only or |
404- | | | writable |
405- +------------------+---------------+-------------------------------+
406- | :attr:`doc` | const char \* | points to the contents of the |
407- | | | docstring |
408- +------------------+---------------+-------------------------------+
390+ .. c:member:: const char* PyMemberDef.name
391+
392+ Name of the member
393+
394+ .. c:member:: int PyMemberDef.type
395+
396+ The type of the member in the C struct.
397+
398+ .. c:member:: Py_ssize_t PyMemberDef. offset
399+
400+ The offset in bytes that the member is located on the type’ s object struct.
401+
402+ .. c:member:: int PyMemberDef.flags
403+
404+ Flag bits indicating if the field should be read-only or writable.
405+
406+ .. c:member:: const char* PyMemberDef.doc
407+
408+ Points to the contents of the docstring.
409409
410- :attr:`! type` can be one of many ``T_`` macros corresponding to various C
410+ :c:member:`PyMemberDef. type` can be one of many ``T_`` macros corresponding to various C
411411 types. When the member is accessed in Python, it will be converted to the
412412 equivalent Python type.
413413
@@ -441,7 +441,7 @@ Accessing attributes of extension types
441441 handles use of the :keyword:`del` statement on that attribute more correctly
442442 than :c:macro:`T_OBJECT`.
443443
444- :attr:` flags` can be ``0`` for write and read access or :c:macro:`READONLY` for
444+ :c:member:`PyMemberDef. flags` can be ``0`` for write and read access or :c:macro:`READONLY` for
445445 read-only access. Using :c:macro:`T_STRING` for :attr:`type` implies
446446 :c:macro:`READONLY`. :c:macro:`T_STRING` data is interpreted as UTF-8.
447447 Only :c:macro:`T_OBJECT` and :c:macro:`T_OBJECT_EX`
0 commit comments