PEP-0263 and default encoding
Martin v. Löwis
martin at v.loewis.de
Wed Oct 1 01:29:39 EDT 2003
"John Roth" <newsgroups at jhrothjr.com> writes:
> > 2. You are writing new code, and you are annoyed by the encoding
> > declaration. Just save your code as UTF-8, using the UTF-8 BOM.
>
> The problem with the UTF-8 BOM is that it precludes using the #! header
> line under Linux/Unix. Otherwise, it's a great solution.
Indeed, in an executable script, you would use the encoding
declaration - or you would restrict yourself to ASCII only in the
script file (which might, as its only action, invoke a function from a
library, in which case there really isn't much need for non-ASCII
characters).
OTOH, I do hope that Unix, some day, recognizes UTF-8-BOM-#-! as
executable file.
Regards,
Martin
More information about the Python-list
mailing list