On Tue, Mar 31, 2020 at 5:10 AM Serhiy Storchaka <[email protected]> wrote: > > 30.03.20 20:27, Chris Angelico пише: > > def __iadd__(self, s): self.data.append(s) > > __iadd__ should return self. >
And that's what I get for quickly whipping something up and not testing it. Good catch. But you get the idea - a simple wrapper around a *list* is going to be way better than a wrapper around StringIO. ChrisA _______________________________________________ Python-ideas mailing list -- [email protected] To unsubscribe send an email to [email protected] https://mail.python.org/mailman3/lists/python-ideas.python.org/ Message archived at https://mail.python.org/archives/list/[email protected]/message/TQIP5EKI3ZZ66LQNQW4YWQ53D6PO6YZN/ Code of Conduct: http://python.org/psf/codeofconduct/
