New submission from Gregory P. Smith: https://docs.python.org/3/c-api/structures.html#c.PyMemberDef
T_STRING members are turned into str objects in Python. The documentation needs updating to mention which codec the char * bytes are treated as. Solving this issue involves code inspection and leaving pointers to that code here in the issue, then updating the docs to mention the requirements for the char * member data as well as what happens upon assignment for non-READONLY T_STRING data (a different restriction? or encoding to the same codec?) My _guess_ would be UTF-8 or ASCII but I'll let someone else dive in and find out. This is a Python 3 specific documentation clarification. ---------- assignee: docs@python components: Documentation keywords: easy messages: 253172 nosy: docs@python, gregory.p.smith priority: normal severity: normal stage: needs patch status: open title: document what codec PyMemberDef T_STRING decodes the char * as type: behavior versions: Python 3.4, Python 3.5, Python 3.6 _______________________________________ Python tracker <rep...@bugs.python.org> <http://bugs.python.org/issue25438> _______________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com