Paul Prescod writes: > The XML rule is one encoding per file. One thing that I think that they > did innovate in (I had nothing to do with that part) is that entities I think an important part of this is that the location of the encoding declaration is completely fixed; it can't start five lines down (after all, it might be hard to know what a line is!). If we say, "The first character of a Python source file must be '#', or assume native encoding.", we go a long way to figuring out what's a line (CR/LF/CRLF can be dealt with in a "universal" fashion), so we can deal with something a little farther down, but I'd hate to be so flexible that it became too tedious to implement. I'd be more accepting of encoding declarations embedded in comments than pragmas. (Not that I *like* abusing comments like that.) So perhaps a Python encoding declaration becomes: #?python encoding="iso-8859-7"?# ;) -Fred -- Fred L. Drake, Jr. <fdrake at acm.org> Corporation for National Research Initiatives
RetroSearch is an open source project built by @garambo | Open a GitHub Issue
Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo
HTML:
3.2
| Encoding:
UTF-8
| Version:
0.7.4