From: Stefan Behnel Date: Fri, 16 May 2008 17:31:39 +0000 (+0200) Subject: cleanup X-Git-Tag: 0.9.8rc1~11^2~10^2~15^2~46 X-Git-Url: http://git.tremily.us/?a=commitdiff_plain;h=eaa1722ebb036eeb39017bbc237ae42ecf00fb36;p=cython.git cleanup --- diff --git a/Cython/Compiler/Nodes.py b/Cython/Compiler/Nodes.py index ec4dfe2a..a352a685 100644 --- a/Cython/Compiler/Nodes.py +++ b/Cython/Compiler/Nodes.py @@ -4351,13 +4351,15 @@ static int __Pyx_InitStrings(__Pyx_StringTabEntry *t) { *t->p = PyUnicode_DecodeUTF8(t->s, t->n - 1, NULL); } else if (t->intern) { *t->p = PyString_InternFromString(t->s); + } #else /* Python 3+ has unicode identifiers */ if (t->is_identifier || (t->is_unicode && t->intern)) { *t->p = PyUnicode_InternFromString(t->s); } else if (t->is_unicode) { *t->p = PyUnicode_FromStringAndSize(t->s, t->n - 1); + } #endif - } else { + else { *t->p = PyString_FromStringAndSize(t->s, t->n - 1); } if (!*t->p)