[Python-Dev] readd u'' literal support in 3.3?

Shane Hathaway shane at hathawaymix.org
Thu Dec 8 19:21:40 CET 2011


On 12/07/2011 11:31 PM, Chris McDonough wrote:
> All I can really offer is my own experience here based on writing code
> that needs to straddle Python 2.5, 2.6, 2.7 and 3.2 without use of 2to3.
> Having u'' work across all of these would mean porting would not require
> as much eyeballing as code modified via "from future import
> unicode_literals", it would let more code work on 2.5 unchanged, and the
> resulting code would execute faster than code that required us to use a
> u() function.

Could you elaborate on why "from __future__ import unicode_literals" is 
inadequate (other than the Python 2.6 requirement)?

Shane


More information about the Python-Dev mailing list