while c = f.read(1)
rafi at free.fr
Tue Aug 23 13:58:17 CEST 2005
Antoon Pardon wrote:
> In that case you wouldn't return an empty sequence if you wanted
> a false value in a sequence context but would throw an exception.
> So this would be fine by me, I just don't understand how this
> would support the use of empty sequences as false.
> I also don't see how a read from a network connection returning
> a bytestring when data is available,
> '' when no data is available
> None when the connection was closed
I do not get why returning '' when no data is available? If no data is
available then nothing is returned, the function hangs. (Which is the
cas for receive)
"Imagination is more important than knowledge."
More information about the Python-list