A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from https://mail.python.org/pipermail/python-dev/2002-June/025757.html below:

[Python-Dev] unifying read method semantics

[Python-Dev] unifying read method semantics [Python-Dev] unifying read method semanticsMartin v. Loewis martin@v.loewis.de
21 Jun 2002 10:46:52 +0200
Piers Lauder <piers@cs.su.oz.au> writes:

> And while I'm on the topic - please could we always support "readline"
> (or "makefile") methods in C modules?  

I don't think this is feasiable.

> Surely the following code now
> necessary in imaplib must make CPU-time conscious programmers wince:
> 
>     def readline(self):
>         """Read line from remote."""
>         line = ""
>         while 1:
>             char = self.sslobj.read(1)
>             line += char
>             if char == "\n": return line

Moving this algorithm to another location won't essentially change CPU
consumption...

Regards,
Martin





RetroSearch is an open source project built by @garambo | Open a GitHub Issue

Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo

HTML: 3.2 | Encoding: UTF-8 | Version: 0.7.4