On 20/03/23 7:07 am, Jon Ribbens wrote:
Ah, apparently it got removed in Python 3, which is a bit odd as the last I heard it was added in Python 2.2 in order to achieve consistency with other types.
As far as I remember, the file type came into existence with type/class unification, and "open" became an alias for the file type, so you could use open() and file() interchangeably. With the Unicode revolution in Python 3, file handling got a lot more complicated. Rather than a single file type, there are now a bunch of classes that handle low-level I/O, encoding/decoding, etc, and open() is a function again that builds the appropriate combination of underlying objects. -- Greg -- https://mail.python.org/mailman/listinfo/python-list