On 17/11/19 10:34 am, Andrew Barnert wrote:
On Nov 16, 2019, at 13:13, Greg Ewing <greg.ew...@canterbury.ac.nz> wrote:
It might be better to keep it as purely a context manager, and
not load it down with any other baggage.
Doesn’t `closing` already take care of that (and other things besides files,
too)?
No, because a tuple of closing(open(...)) calls still opens all the
files before the with-statement starts.
--
Greg
_______________________________________________
Python-ideas mailing list -- python-ideas@python.org
To unsubscribe send an email to python-ideas-le...@python.org
https://mail.python.org/mailman3/lists/python-ideas.python.org/
Message archived at
https://mail.python.org/archives/list/python-ideas@python.org/message/OVKPFPCCO5ITHNWYBX6ICC7XAT6DQILA/
Code of Conduct: http://python.org/psf/codeofconduct/