From: Ben Darnell Date: Sun, 9 Aug 2015 03:04:27 +0000 (-0400) Subject: Third time's the charm for _locale_data.py X-Git-Tag: v4.3.0b1~57 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=376e1cef3f1ca01b4ddeb096639fb4aabd4fa068;p=thirdparty%2Ftornado.git Third time's the charm for _locale_data.py --- diff --git a/tornado/_locale_data.py b/tornado/_locale_data.py index d28ab8074..caf0f0605 100644 --- a/tornado/_locale_data.py +++ b/tornado/_locale_data.py @@ -17,7 +17,14 @@ """Data used by the tornado.locale module.""" -from tornado.util import u +# NOTE: This file is supposed to contain unicode strings, which is +# exactly what you'd get with e.g. u"Español" in most python versions. +# However, Python 3.2 doesn't support the u"" syntax, so we use a u() +# function instead. tornado.util.u cannot be used because it doesn't +# support non-ascii characters on python 2. +# When we drop support for Python 3.2, we can remove the parens +# and make these plain unicode strings. +from tornado.escape import to_unicode as u LOCALE_NAMES = { "af_ZA": {"name_en": u("Afrikaans"), "name": u("Afrikaans")},