This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author serhiy.storchaka
Recipients christian.heimes, docs@python, serhiy.storchaka, skip.montanaro
Date 2016-10-03.18:07:59
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1475518079.81.0.844864411163.issue28349@psf.upfronthosting.co.za>
In-reply-to
Content
As documented in Doc/extending/newtypes.rst, the flags field of PyMemberDef must be bitwise-or-ed combination of flag constants READONLY, READ_RESTRICTED, WRITE_RESTRICTED and RESTRICTED. There are problems with this:

1. Actually WRITE_RESTRICTED was renamed to PY_WRITE_RESTRICTED in 2.6 (a8dd8874ff2d). I didn't find mention of this backward incompatible change in Misc/NEWS and whatsnew files.

2. Since the support of restricted mode was removed in 3.x, only READONLY flag has effect. Other flags are still documented and used in CPython sources. I think we should get rid of using these flags and undocument them or document as outdated.

3. As noted by Skip Montanaro on the Python-Dev mailing list, these flags (as well as T_* type tags in Include/structmember.h) should have the PY_ prefix.
History
Date User Action Args
2016-10-03 18:07:59serhiy.storchakasetrecipients: + serhiy.storchaka, skip.montanaro, christian.heimes, docs@python
2016-10-03 18:07:59serhiy.storchakasetmessageid: <1475518079.81.0.844864411163.issue28349@psf.upfronthosting.co.za>
2016-10-03 18:07:59serhiy.storchakalinkissue28349 messages
2016-10-03 18:07:59serhiy.storchakacreate