From e716ffe7806688416866dcab49ed7ec36c19a657 Mon Sep 17 00:00:00 2001 From: "Gustavo J. A. M. Carneiro" Date: Fri, 8 Aug 2008 17:24:28 +0100 Subject: [PATCH] Fix bad PY_VERSION_HEX values. --- pybindgen/utils.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pybindgen/utils.py b/pybindgen/utils.py index 997278c..f7d730c 100644 --- a/pybindgen/utils.py +++ b/pybindgen/utils.py @@ -38,7 +38,7 @@ def write_preamble(code_sink, min_python_version=None): if min_python_version < (2, 4): code_sink.writeln(r''' -#if PY_VERSION_HEX < 0x02040000 +#if PY_VERSION_HEX < 0x020400F0 #define PyEval_ThreadsInitialized() 1 @@ -67,7 +67,7 @@ def write_preamble(code_sink, min_python_version=None): if min_python_version < (2, 5): code_sink.writeln(r''' -#if PY_VERSION_HEX < 0x02050000 +#if PY_VERSION_HEX < 0x020500F0 typedef int Py_ssize_t; # define PY_SSIZE_T_MAX INT_MAX