[Python-Dev] PEP 414 (original) (raw)

Lennart Regebro regebro at gmail.com
Sat Mar 3 07:20:14 CET 2012


On Sat, Mar 3, 2012 at 01:49, <martin at v.loewis.de> wrote:

Zitat von Lennart Regebro <regebro at gmail.com>:

Just my 2 cents on the PEP rewrite: u'' support is not just if you want to write code that doesn't use 2to3. Even when you use 2to3 it is useful to be able to flag strings s binary, unicode or "native". How so? In the Python 3 code, the u"" prefix would not appear, even if appears in the original source, as 2to3 eliminates it.

Well, not if you disable that fixer. ;-)

But you are right, it isn't necessary. I was thinking of 3to2, actually. That was one of the objections I had to the usefulness of 3to2, there is no way to make the distinction between unicode and native strings. (The u'' prefix hence actually makes 3to2 a realistic option, and that's good.)

So everyone can ignore this, I mixed up two issues. :-)

//Lennart



More information about the Python-Dev mailing list