Commit c8788e84 authored by jack's avatar jack

Added a version attribute (and upped the version to 1.2).

parent 6306f16d
......@@ -5,7 +5,7 @@ _checkversion.py file"""
import pyversioncheck
_PACKAGE="pyexpat"
_VERSION="1.1"
_VERSION="1.2"
_URL="http://www.cwi.nl/~jack/pyexpatversion.txt"
try:
......
......@@ -32,6 +32,11 @@ PERFORMANCE OF THIS SOFTWARE.
#include "Python.h"
#include "xmlparse.h"
/*
** The version number should match the one in _checkversion
*/
#define VERSION "1.2"
static PyObject *ErrorObject;
/* ----------------------------------------------------- */
......@@ -408,8 +413,11 @@ initpyexpat()
PyDict_SetItemString(d, "error", ErrorObject);
/* XXXX Add constants here */
PyDict_SetItemString(d, "version", PyString_FromString(VERSION));
#define MYCONST(name) \
PyDict_SetItemString(d, #name, PyInt_FromLong(name))
MYCONST(XML_ERROR_NONE);
MYCONST(XML_ERROR_NO_MEMORY);
MYCONST(XML_ERROR_SYNTAX);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment