[issue8711] Document PyUnicode_DecodeFSDefault() and PyUnicode_DecodeFSDefaultAndSize()

New submission from STINNER Victor <victor.stinner@haypocalc.com>: Attached patch document PyUnicode_DecodeFSDefault() and PyUnicode_DecodeFSDefaultAndSize() in Doc/c-api/, and fix comment in Include/unicodeobject.c (remove reference to bytearray, and specify that surrogateescape is used). The patch adds also titles to group unicode functions and methods by topic. ---------- assignee: docs@python components: Documentation, Unicode files: unicode_doc.patch keywords: patch messages: 105706 nosy: docs@python, haypo priority: normal severity: normal status: open title: Document PyUnicode_DecodeFSDefault() and PyUnicode_DecodeFSDefaultAndSize() versions: Python 3.1, Python 3.2 Added file: http://bugs.python.org/file17336/unicode_doc.patch _______________________________________ Python tracker <report@bugs.python.org> <http://bugs.python.org/issue8711> _______________________________________

Éric Araujo <merwok@netwok.org> added the comment: The bulk of the patch seems good to me, with some minor remarks: - You haven’t used title case consistently in all section titles. - I’d just say “wchar_t Support” in a title, deleting “for platforms which support it”. - You could mark up “bytes” so that users get a link. - The verb form of “fall back” is in two words, unless I’m lagging on current technical English. - You lack an article when saying “the "surrogateescape" error handler”. - Not sure: Is it better to say “for encoding x, use y” or “to encode x, use y”? Sorry for not giving precise line numbers or a diff of a diff, that wouldn’t be practical. ---------- nosy: +merwok title: Document PyUnicode_DecodeFSDefault() and PyUnicode_DecodeFSDefaultAndSize() -> Document PyUnicode_DecodeFSDefault() and PyUnicode_DecodeFSDefaultAndSize() _______________________________________ Python tracker <report@bugs.python.org> <http://bugs.python.org/issue8711> _______________________________________

Antoine Pitrou <pitrou@free.fr> added the comment:
Is it better to say “for encoding x, use y” or “to encode x, use y”?
The latter, IMO. "Encoding" is also a noun. ---------- nosy: +pitrou _______________________________________ Python tracker <report@bugs.python.org> <http://bugs.python.org/issue8711> _______________________________________

Éric Araujo <merwok@netwok.org> added the comment: In this case, it was a verb (a gerund form). ---------- title: Document PyUnicode_DecodeFSDefault() and PyUnicode_DecodeFSDefaultAndSize() -> Document PyUnicode_DecodeFSDefault() and PyUnicode_DecodeFSDefaultAndSize() _______________________________________ Python tracker <report@bugs.python.org> <http://bugs.python.org/issue8711> _______________________________________

STINNER Victor <victor.stinner@haypocalc.com> added the comment: Thanks for your remarks: updated patch. ---------- Added file: http://bugs.python.org/file17339/unicode_doc-2.patch _______________________________________ Python tracker <report@bugs.python.org> <http://bugs.python.org/issue8711> _______________________________________

STINNER Victor <victor.stinner@haypocalc.com> added the comment: Commited: r81168 (py3k), r81169 (3.1). I also added the paragraph titles to Python2: r81166 (trunk) and r81167 (2.6). ---------- resolution: -> fixed status: open -> closed _______________________________________ Python tracker <report@bugs.python.org> <http://bugs.python.org/issue8711> _______________________________________

Éric Araujo <merwok@netwok.org> added the comment: The bulk of the patch seems good to me, with some minor remarks: - You haven’t used title case consistently in all section titles. - I’d just say “wchar_t Support” in a title, deleting “for platforms which support it”. - You could mark up “bytes” so that users get a link. - The verb form of “fall back” is in two words, unless I’m lagging on current technical English. - You lack an article when saying “the "surrogateescape" error handler”. - Not sure: Is it better to say “for encoding x, use y” or “to encode x, use y”? Sorry for not giving precise line numbers or a diff of a diff, that wouldn’t be practical. ---------- nosy: +merwok title: Document PyUnicode_DecodeFSDefault() and PyUnicode_DecodeFSDefaultAndSize() -> Document PyUnicode_DecodeFSDefault() and PyUnicode_DecodeFSDefaultAndSize() _______________________________________ Python tracker <report@bugs.python.org> <http://bugs.python.org/issue8711> _______________________________________

Antoine Pitrou <pitrou@free.fr> added the comment:
Is it better to say “for encoding x, use y” or “to encode x, use y”?
The latter, IMO. "Encoding" is also a noun. ---------- nosy: +pitrou _______________________________________ Python tracker <report@bugs.python.org> <http://bugs.python.org/issue8711> _______________________________________

Éric Araujo <merwok@netwok.org> added the comment: In this case, it was a verb (a gerund form). ---------- title: Document PyUnicode_DecodeFSDefault() and PyUnicode_DecodeFSDefaultAndSize() -> Document PyUnicode_DecodeFSDefault() and PyUnicode_DecodeFSDefaultAndSize() _______________________________________ Python tracker <report@bugs.python.org> <http://bugs.python.org/issue8711> _______________________________________

STINNER Victor <victor.stinner@haypocalc.com> added the comment: Thanks for your remarks: updated patch. ---------- Added file: http://bugs.python.org/file17339/unicode_doc-2.patch _______________________________________ Python tracker <report@bugs.python.org> <http://bugs.python.org/issue8711> _______________________________________

STINNER Victor <victor.stinner@haypocalc.com> added the comment: Commited: r81168 (py3k), r81169 (3.1). I also added the paragraph titles to Python2: r81166 (trunk) and r81167 (2.6). ---------- resolution: -> fixed status: open -> closed _______________________________________ Python tracker <report@bugs.python.org> <http://bugs.python.org/issue8711> _______________________________________
participants (3)
-
Antoine Pitrou
-
STINNER Victor
-
Éric Araujo