From: Stefan Behnel Date: Wed, 15 Aug 2012 10:47:12 +0000 (+0200) Subject: remove duplicated condition X-Git-Tag: 0.17b3~44 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=001377128b9aa554672b88d06a3975dbdb70abe8;p=platform%2Fupstream%2Fpython-cython.git remove duplicated condition --- diff --git a/Cython/Compiler/ModuleNode.py b/Cython/Compiler/ModuleNode.py index e976042..8cf74ae 100644 --- a/Cython/Compiler/ModuleNode.py +++ b/Cython/Compiler/ModuleNode.py @@ -1923,7 +1923,7 @@ class ModuleNode(Nodes.Node, Nodes.BlockNode): code.globalstate.get_py_string_const( EncodedString(decode_filename(module_path))).cname, code.error_goto(self.pos))) - if os.path.splitext(os.path.basename(module_path))[0] == '__init__': + if env.is_package: # compiling a package => set __path__ as well temp = code.funcstate.allocate_temp(py_object_type, True) code.putln('%s = Py_BuildValue("[O]", %s); %s' % (