[Python-Dev] sizehint in readlines

M.-A. Lemburg mal@lemburg.com
Tue, 19 Sep 2000 14:42:24 +0200

Martin von Loewis wrote:
> I've added support for the sizehint parameter in all places where it
> was missing and the documentation referred to the file objects section
> (socket, StringIO, cStringIO). The only remaining place with a
> readlines function without sizehint is in multifile.py. I'll observe
> that the documentation of this module is quite confused: it mentions a
> str parameter for readline and readlines.
> Should multifile.MultiFile.readlines also support the sizehint? (note
> that read() deliberately does not support a size argument).

Since it is an optional hint for the implementation, I'd suggest
adding the optional parameter without actually making any use of
it. The interface should be there though.

Marc-Andre Lemburg
Business:                                      http://www.lemburg.com/
Python Pages:                           http://www.lemburg.com/python/