homepage

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 chris.jerdonek
Recipients chris.jerdonek, docs@python
Date 2012年08月11日.19:14:22
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1344712464.43.0.600420981046.issue15624@psf.upfronthosting.co.za>
In-reply-to
Content
The documentation of io.TextIOWrapper's newline argument is somewhat confusing and perhaps reversed from what was intended. (For example, the subprocess module uses the reverse terminology.) Either way, it can be improved somewhat. Currently, it says--
"* On input, if newline is None,... Lines in the input can end in '\n', '\r', or '\r\n', and these are translated into '\n' before being returned to the caller...
* On output, if newline is None, any '\n' characters written are translated to the system default line separator, os.linesep..."
(from http://docs.python.org/dev/library/io.html#io.TextIOWrapper )
It is somewhat confusing because "On input" does not mean "On input to the buffer," and "On output" does not mean "On output from the buffer." It is the reverse.
A minimal change to address this would be something along the lines of--
"On input" -> "When reading input from the buffer"
"On output" -> "When writing output to the buffer
The same change could also be made to the open() documentation:
http://docs.python.org/dev/library/functions.html#open
I can prepare a patch for affected versions.
History
Date User Action Args
2012年08月11日 19:14:24chris.jerdoneksetrecipients: + chris.jerdonek, docs@python
2012年08月11日 19:14:24chris.jerdoneksetmessageid: <1344712464.43.0.600420981046.issue15624@psf.upfronthosting.co.za>
2012年08月11日 19:14:23chris.jerdoneklinkissue15624 messages
2012年08月11日 19:14:22chris.jerdonekcreate

AltStyle によって変換されたページ (->オリジナル) /