April 4, 2002
3:25 p.m.
Neil Schemenauer wrote:
You can use a macro like this:
#if PY_VERSION_HEX < 0x01060000 #define PyObject_New PyObject_NEW #define PyObject_Del PyMem_DEL #endif
I just realized that this may be unclear. You don't _need_ to use the above macro to make your code work across versions. As long as you use PyMem_DEL and not free() to deallocate objects the code will work. Neil