Use ValueError instead of SyntaxError throughout.
authorMark Wooding <mdw@distorted.org.uk>
Fri, 29 May 2015 08:34:09 +0000 (09:34 +0100)
committerMark Wooding <mdw@distorted.org.uk>
Fri, 29 May 2015 08:34:09 +0000 (09:34 +0100)
SyntaxError has a much more specific meaning, and some software, such as
`ipython', expect it to carry lots of other detailed information.

So abolish the `SYNERR' macro, and use `VALERR' instead consistently.  I
wish I had an excuse for this blunder, but I don't.

catacomb-python.h

index bb84a74..b287450 100644 (file)
 #define VALERR(str) EXCERR(PyExc_ValueError, str)
 #define TYERR(str) EXCERR(PyExc_TypeError, str)
 #define ZDIVERR(str) EXCERR(PyExc_ZeroDivisionError, str)
-#define SYNERR(str) EXCERR(PyExc_SyntaxError, str)
 #define SYSERR(str) EXCERR(PyExc_SystemError, str)
 #define NIERR(str) EXCERR(PyExc_NotImplementedError, str)
 #define INDEXERR(idx) do {                                             \