[Python-Dev] io.BufferedReader.peek() Behaviour in python3.1

Antoine Pitrou solipsis at pitrou.net
Wed Jun 17 01:38:49 CEST 2009

Greg Ewing <greg.ewing <at> canterbury.ac.nz> writes:
> Anything else such as peek() that doesn't explicitly
> mention the buffer should fit into the abstraction
> properly.

peek() doesn't "fit into the abstraction" since it doesn't even exist on raw

While buffered and non-buffered streams have a reasonably similar API, expecting
them to behave the same in all circumstances is IMO unrealistic.


More information about the Python-Dev mailing list