From 5724798eae9aabeee42f7e36871f0a67b3f7ffb8 Mon Sep 17 00:00:00 2001 From: Stefan Behnel Date: Sun, 14 Mar 2010 16:28:27 +0100 Subject: [PATCH] code cleanup --- Cython/Compiler/ModuleNode.py | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/Cython/Compiler/ModuleNode.py b/Cython/Compiler/ModuleNode.py index c0010d77..072e7153 100644 --- a/Cython/Compiler/ModuleNode.py +++ b/Cython/Compiler/ModuleNode.py @@ -1652,11 +1652,7 @@ class ModuleNode(Nodes.Node, Nodes.BlockNode): self.generate_filename_init_call(code) code.putln("%s = PyTuple_New(0); %s" % (Naming.empty_tuple, code.error_goto_if_null(Naming.empty_tuple, self.pos))); - code.putln("#if PY_MAJOR_VERSION < 3"); - code.putln("%s = PyString_FromStringAndSize(\"\", 0); %s" % (Naming.empty_bytes, code.error_goto_if_null(Naming.empty_bytes, self.pos))); - code.putln("#else"); - code.putln("%s = PyBytes_FromStringAndSize(\"\", 0); %s" % (Naming.empty_bytes, code.error_goto_if_null(Naming.empty_bytes, self.pos))); - code.putln("#endif"); + code.putln("%s = __Pyx_PyBytes_FromStringAndSize(\"\", 0); %s" % (Naming.empty_bytes, code.error_goto_if_null(Naming.empty_bytes, self.pos))); code.putln("/*--- Library function declarations ---*/") env.generate_library_function_declarations(code) -- 2.26.2