On Nov 19, 2019, at 09:40, Rhodri James <rho...@kynesim.co.uk> wrote: > > > How about using Paths as file context managers? Just an idle thought.
Then how do you open a Path for writing, or in binary mode, etc.? Adding a Path.opening method that returns an file-on-enter context manager instead of a file would probably work. But is that better than an opening function that takes a Path (or any of the other valid arguments to open) as its first argument? _______________________________________________ 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/Y5RFSKGFSDGUWUE7TK2FDWTY57CYION4/ Code of Conduct: http://python.org/psf/codeofconduct/