From e351aa7da675f245cb3bc1f342d6ac7fa35d7294 Mon Sep 17 00:00:00 2001 From: Nikita Nemkin Date: Tue, 5 Mar 2013 22:44:28 +0600 Subject: [PATCH] More pyunicode_ptr renames. --- Cython/Compiler/Code.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/Cython/Compiler/Code.py b/Cython/Compiler/Code.py index c4ebe4d..6cb1edd 100644 --- a/Cython/Compiler/Code.py +++ b/Cython/Compiler/Code.py @@ -873,7 +873,7 @@ class GlobalState(object): self.const_cname_counter = 1 self.string_const_index = {} - self.unicode_const_index = {} + self.pyunicode_ptr_const_index = {} self.int_const_index = {} self.py_constants = [] @@ -1021,9 +1021,9 @@ class GlobalState(object): # return a Py_UNICODE[] constant, creating a new one if necessary assert text.is_unicode try: - c = self.unicode_const_index[text] + c = self.pyunicode_ptr_const_index[text] except KeyError: - c = self.unicode_const_index[text] = self.new_const_cname() + c = self.pyunicode_ptr_const_index[text] = self.new_const_cname() return c def get_py_string_const(self, text, identifier=None, @@ -1151,7 +1151,7 @@ class GlobalState(object): for py_string in c.py_strings.values(): py_strings.append((c.cname, len(py_string.cname), py_string)) - for c, cname in self.unicode_const_index.items(): + for c, cname in self.pyunicode_ptr_const_index.items(): utf16_array, utf32_array = StringEncoding.encode_pyunicode_string(c) if utf16_array: # Narrow and wide representations differ -- 2.7.4