[Pythonmac-SIG] Re: [Python-Dev] Import hook to do end-of-line conversion?
Guido van Rossum
guido@digicool.com
Mon, 09 Apr 2001 21:33:53 -0500
> Disregard what I just said. The problem isn't about reading
> text files at all, it's about reading non-text files without
> explicitly opening them in binary mode.
What I said. :-)
> I think the trouble is with the idea that if you don't
> specify the mode explicitly it defaults to text mode, which
> on Unix just happens to be the same as binary mode.
>
> Could we change that so binary mode is the default on
> Unix, and if you want any line ending translation, you
> have to specify text mode explicitly? Is there any standard
> which says that text mode must be the default?
It's pretty clear that the default is text mode. But we could add a
new mode character, 't', to force text mode on.
--Guido van Rossum (home page: http://www.python.org/~guido/)