R. David Murray added the comment:

So you are saying that BytesIO has code that checks that its argument only has 
a single reference and modifies the string in place when it can if so?  You 
can't depend on that in any other implementation of Python, and shouldn't 
depend on it in CPython either.  Even in CPython you can't guarantee that case 
1 is case 1, since the argument could conceivably be an interned string.

So the seek approach is the only one that makes semantic sense, I think.

----------

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

Reply via email to