[Python-Dev] PEP 414 - Unicode Literals for Python 3
Serhiy Storchaka
storchaka at gmail.com
Mon Feb 27 23:38:14 CET 2012
28.02.12 00:11, Armin Ronacher написав(ла):
> On 2/27/12 9:58 PM, R. David Murray wrote:
>> But the PEP doesn't address the unicode_literals plus str() approach.
>> That is, the rationale currently makes a false claim.
> Which would be exactly what that u() does not do?
No.
1. u() is trivial for Python 3 and relatively expensive (and doubtful
for non-ascii literals) for Python 2, unicode_literals plus str() is
trivial for Python 3 and cheap for Python 2.
2. Text strings are natural and prevalent, but "natural" strings are
domain-specific and archaic.
More information about the Python-Dev
mailing list