STINNER Victor <victor.stin...@haypocalc.com> added the comment:

textiowrapper_interlaced_read_write.patch: TextIOWrapper.write() calls 
self.seek(self.tell()) if it has a decoder or if snapshot is not None.

I suppose that we can do better, but at least it does fix this issue.

"read(); write(); write()" only calls self.seek(self.tell()) once, at the first 
write. So I don't think that it changes anything with performances.

In which case snapshot can be not different than None, whereas decoder is None?

----------
keywords: +patch
Added file: 
http://bugs.python.org/file22192/textiowrapper_interlaced_read_write.patch

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

Reply via email to