mirror of
https://github.com/python/cpython.git
synced 2025-10-06 15:11:58 +00:00
New functions for extension writers on Windows:
PyErr_SetExcFromWindowsErr(), PyErr_SetExcFromWindowsErrWithFilename(). Similar to PyErr_SetFromWindowsErrWithFilename() and PyErr_SetFromWindowsErr(), but they allow to specify the exception type to raise. Available on Windows. See SF patch #576458.
This commit is contained in:
parent
b9e0764d8b
commit
085358a3e2
4 changed files with 42 additions and 3 deletions
|
@ -83,6 +83,9 @@ extern DL_IMPORT(PyObject *) PyErr_Format(PyObject *, const char *, ...)
|
|||
#ifdef MS_WINDOWS
|
||||
extern DL_IMPORT(PyObject *) PyErr_SetFromWindowsErrWithFilename(int, const char *);
|
||||
extern DL_IMPORT(PyObject *) PyErr_SetFromWindowsErr(int);
|
||||
extern DL_IMPORT(PyObject *) PyErr_SetExcFromWindowsErrWithFilename(
|
||||
PyObject *,int, const char *);
|
||||
extern DL_IMPORT(PyObject *) PyErr_SetExcFromWindowsErr(PyObject *, int);
|
||||
#endif
|
||||
|
||||
/* Export the old function so that the existing API remains available: */
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue