Martin Panter added the comment:

After thinking about Issue 26720 (see also Issue 15994), I think it might be 
worth documenting not only that bytes-like objects may be passed, but in some 
cases the class should not be access the object after the method returns. This 
applies to at least RawIOBase.readinto() and especially RawIOBase.write(). If 
you want to save the write() data in memory, you have to make a copy, because 
the original may be lost when BufferedWriter overwrites its internal buffeer.

----------

_______________________________________
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue20699>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com

Reply via email to