From: Stefan Behnel Date: Sun, 11 Oct 2009 08:26:56 +0000 (+0200) Subject: fix builtins after identifier changes X-Git-Tag: 0.13.beta0~2^2~121^2~75 X-Git-Url: http://git.tremily.us/?a=commitdiff_plain;h=1ae3e5c5c95e3da08354ba8de71e5b233cd720e5;p=cython.git fix builtins after identifier changes --- diff --git a/Cython/Compiler/Code.py b/Cython/Compiler/Code.py index 99e85689..d864229d 100644 --- a/Cython/Compiler/Code.py +++ b/Cython/Compiler/Code.py @@ -559,6 +559,9 @@ class GlobalState(object): py_string = c_string.get_py_string_const(text.encoding, identifier, is_str) return py_string + def get_interned_identifier(self, text): + return self.get_py_string_const(text, identifier=True) + def new_string_const(self, text, byte_string): cname = self.new_string_const_cname(byte_string) c = StringConst(cname, text, byte_string) @@ -604,7 +607,7 @@ class GlobalState(object): def add_cached_builtin_decl(self, entry): if Options.cache_builtins: if self.should_declare(entry.cname, entry): - interned_cname = self.intern_identifier(entry.name).cname + interned_cname = self.get_interned_identifier(entry.name).cname self.put_pyobject_decl(entry) w = self.parts['cached_builtins'] w.putln('%s = __Pyx_GetName(%s, %s); if (!%s) %s' % (