diff options
author | Stefan Behnel <stefan_ml@behnel.de> | 2013-03-09 14:24:31 +0100 |
---|---|---|
committer | Stefan Behnel <stefan_ml@behnel.de> | 2013-03-09 14:24:31 +0100 |
commit | 97f8a2293987ea10961a7101c9025215aa9cbdfc (patch) | |
tree | 72f485d4b50fe6f49a3d66460cb622283749f650 /Cython/Compiler/ModuleNode.py | |
parent | f913f4d3d0a95a6ff293e5b3af3983683a0eab1c (diff) | |
download | cython-97f8a2293987ea10961a7101c9025215aa9cbdfc.tar.gz |
simplify some Py3 precompiler checks
Diffstat (limited to 'Cython/Compiler/ModuleNode.py')
-rw-r--r-- | Cython/Compiler/ModuleNode.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/Cython/Compiler/ModuleNode.py b/Cython/Compiler/ModuleNode.py index aeb2cad94..502175402 100644 --- a/Cython/Compiler/ModuleNode.py +++ b/Cython/Compiler/ModuleNode.py @@ -1941,7 +1941,7 @@ class ModuleNode(Nodes.Node, Nodes.BlockNode): code.putln("/*--- Initialize various global constants etc. ---*/") code.putln(code.error_goto_if_neg("__Pyx_InitGlobals()", self.pos)) - code.putln("#if PY_VERSION_HEX < 0x03000000 && (__PYX_DEFAULT_STRING_ENCODING_IS_ASCII || __PYX_DEFAULT_STRING_ENCODING_IS_DEFAULT)") + code.putln("#if PY_MAJOR_VERSION < 3 && (__PYX_DEFAULT_STRING_ENCODING_IS_ASCII || __PYX_DEFAULT_STRING_ENCODING_IS_DEFAULT)") code.putln("if (__Pyx_init_sys_getdefaultencoding_params() < 0) %s" % code.error_goto(self.pos)) code.putln("#endif") |