I wrote:

> Here's a small example of a ZipFile subclass (tested a bit this time)
> that implements two generator methods:

Argh, not quite tested enough - one fix needed, change:

            if bytes[-1] not in ('\n', '\r'):
                partial = lines.pop()

to:

            if bytes[-1] not in ('\n', '\r'):
                partial = lines.pop()
            else:
                partial = ''

(add the extra two lines)

-- David
-- 
http://mail.python.org/mailman/listinfo/python-list

Reply via email to