A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from https://mail.python.org/pipermail/python-dev/2011-February/108240.html below:

[Python-Dev] Strange error importing a Pickle from 2.7 to 3.2

[Python-Dev] Strange error importing a Pickle from 2.7 to 3.2 [Python-Dev] Strange error importing a Pickle from 2.7 to 3.2Alexander Belopolsky alexander.belopolsky at gmail.com
Wed Feb 23 22:13:14 CET 2011
On Wed, Feb 23, 2011 at 4:07 PM, Guido van Rossum <guido at python.org> wrote:
> I'm guessing that one of these encoding names is recognized by the C
> code while the other one takes the slow path via the aliasing code.

This is absolutely right.  In fact I am going to propose adding
strcmp(lower, "latin1") to the following test in
PyUnicode_AsEncodedString():


	else if ((strcmp(lower, "latin-1") == 0) ||
                 (strcmp(lower, "iso-8859-1") == 0))
            return PyUnicode_EncodeLatin1(...

I'll open a separate issue for that.  In Python's own stdlib and tests
"latin1" is a more common spelling than "latin-1", so it makes sense
to optimize it.
More information about the Python-Dev mailing list

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