projects
/
cython.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
8b6332e
)
compatibility fix for Python 2.4
author
Lisandro Dalcin
<dalcinl@gmail.com>
Fri, 26 Mar 2010 17:07:54 +0000
(14:07 -0300)
committer
Lisandro Dalcin
<dalcinl@gmail.com>
Fri, 26 Mar 2010 17:07:54 +0000
(14:07 -0300)
Cython/Compiler/ModuleNode.py
patch
|
blob
|
history
diff --git
a/Cython/Compiler/ModuleNode.py
b/Cython/Compiler/ModuleNode.py
index 722293760b4737b26085271dc531d0e871f96b3e..56fb98b7fbc7b93d7cf0e0bc5cc801326eca5105 100644
(file)
--- a/
Cython/Compiler/ModuleNode.py
+++ b/
Cython/Compiler/ModuleNode.py
@@
-2180,7
+2180,11
@@
static PyTypeObject *__Pyx_ImportType(const char *module_name, const char *class
PyOS_snprintf(warning, sizeof(warning),
"%s.%s size changed, may indicate binary incompatibility",
module_name, class_name);
+ #if PY_VERSION_HEX < 0x02050000
+ PyErr_Warn(NULL, warning);
+ #else
PyErr_WarnEx(NULL, warning, 0);
+ #endif
}
else if (((PyTypeObject *)result)->tp_basicsize != size) {
PyErr_Format(PyExc_ValueError,