[Python-checkins] python/dist/src/Include pyerrors.h,2.67,2.68

rhettinger@users.sourceforge.net rhettinger at users.sourceforge.net
Sat Aug 6 20:31:27 CEST 2005


Update of /cvsroot/python/python/dist/src/Include
In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv5206/Include

Modified Files:
	pyerrors.h 
Log Message:
* set_new() doesn't need to zero the structure a second time after tp_alloc
  has already done the job.
* Use a macro form of PyErr_Occurred() inside the set_lookkey() function.



Index: pyerrors.h
===================================================================
RCS file: /cvsroot/python/python/dist/src/Include/pyerrors.h,v
retrieving revision 2.67
retrieving revision 2.68
diff -u -d -r2.67 -r2.68
--- pyerrors.h	2 Aug 2005 00:46:42 -0000	2.67
+++ pyerrors.h	6 Aug 2005 18:31:24 -0000	2.68
@@ -15,6 +15,12 @@
 PyAPI_FUNC(void) PyErr_Fetch(PyObject **, PyObject **, PyObject **);
 PyAPI_FUNC(void) PyErr_Restore(PyObject *, PyObject *, PyObject *);
 
+#ifdef Py_DEBUG
+#define _PyErr_OCCURRED() PyErr_Occurred()
+#else
+#define _PyErr_OCCURRED() (_PyThreadState_Current->curexc_type)
+#endif
+
 /* Error testing and normalization */
 PyAPI_FUNC(int) PyErr_GivenExceptionMatches(PyObject *, PyObject *);
 PyAPI_FUNC(int) PyErr_ExceptionMatches(PyObject *);



More information about the Python-checkins mailing list