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.
Created on 2014年09月25日 07:02 by georg.brandl, last changed 2022年04月11日 14:58 by admin. This issue is now closed.
| Files | ||||
|---|---|---|---|---|
| File name | Uploaded | Description | Edit | |
| print_binary.diff | georg.brandl, 2014年09月25日 07:02 | review | ||
| print-22492-34.diff | terry.reedy, 2014年09月30日 23:49 | review | ||
| Messages (4) | |||
|---|---|---|---|
| msg227509 - (view) | Author: Georg Brandl (georg.brandl) * (Python committer) | Date: 2014年09月25日 07:02 | |
This is implicit in the "converts arguments to strings", but people might reasonably expect that print(x, file=y) is the same as y.write(x) for strings and bytes. This paragraph makes it clear. |
|||
| msg228037 - (view) | Author: Terry J. Reedy (terry.reedy) * (Python committer) | Date: 2014年09月30日 23:49 | |
Agreed. Here is a patch I will commit if you approve. I deleted 'convenience function' as distracting, labelled *file* a *text* stream in the first line, and added the rest of the comment after the current 'file' sentence, making separate 'file' and 'flush' paragraphs. I unstarred 'file' in the addition to try to make it slightly clearer that the comment applies to the default sys.stdout, when rebound to a binary mode file, as well as to explicit *file=* arguments. |
|||
| msg228064 - (view) | Author: Georg Brandl (georg.brandl) * (Python committer) | Date: 2014年10月01日 09:38 | |
Looks good. > sys.stdout, when rebound to a binary mode file Not sure that is supported in any way :) |
|||
| msg228110 - (view) | Author: Roundup Robot (python-dev) (Python triager) | Date: 2014年10月01日 19:40 | |
New changeset 9b519f72860a by Terry Jan Reedy in branch '3.4': Issue 22492: Be explicit that print does not support binary mode files. https://hg.python.org/cpython/rev/9b519f72860a |
|||
| History | |||
|---|---|---|---|
| Date | User | Action | Args |
| 2022年04月11日 14:58:08 | admin | set | github: 66682 |
| 2014年10月01日 19:40:58 | terry.reedy | set | status: open -> closed assignee: terry.reedy resolution: fixed stage: commit review -> resolved |
| 2014年10月01日 19:40:17 | python-dev | set | nosy:
+ python-dev messages: + msg228110 |
| 2014年10月01日 09:38:39 | georg.brandl | set | messages: + msg228064 |
| 2014年09月30日 23:49:59 | terry.reedy | set | files:
+ print-22492-34.diff type: enhancement versions: + Python 3.4, Python 3.5 nosy: + terry.reedy messages: + msg228037 stage: commit review |
| 2014年09月25日 07:02:28 | georg.brandl | create | |