From a42fcbf32bc5d91db4cc7d67697398f0e5214249 Mon Sep 17 00:00:00 2001 From: Stefan Behnel Date: Sat, 21 Feb 2009 18:07:01 +0100 Subject: [PATCH] fix long literals in Py3 --- Cython/Compiler/Code.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Cython/Compiler/Code.py b/Cython/Compiler/Code.py index 55742e60..99c0203f 100644 --- a/Cython/Compiler/Code.py +++ b/Cython/Compiler/Code.py @@ -354,7 +354,7 @@ class GlobalState(object): if entry.init[-1] == "L": self.initwriter.putln('%s = PyLong_FromString((char *)"%s", 0, 0); %s;' % ( entry.cname, - entry.init, + entry.init[:-1], self.initwriter.error_goto_if_null(entry.cname, self.module_pos))) else: self.initwriter.putln("%s = PyInt_FromLong(%s); %s;" % ( -- 2.26.2