fixes for the examples and tcl to use the old Tcl_SetResult()... methods
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk/SWIG@7962 626c5289-ae23-0410-ae9c-e8d60b6d4f22
This commit is contained in:
parent
99f0122d0d
commit
efcc7aeacf
8 changed files with 47 additions and 17 deletions
|
|
@ -47,10 +47,10 @@
|
|||
try {
|
||||
$action
|
||||
} catch(FullError& e) {
|
||||
FullError *ecopy = new FullError(e);
|
||||
PyObject *err = SWIG_NewPointerObj(ecopy, SWIGTYPE_p_FullError, 1);
|
||||
PyErr_SetObject((PyObject *) SWIGTYPE_p_FullError->clientdata, err);
|
||||
return NULL;
|
||||
FullError *ecopy = new FullError(e);
|
||||
PyObject *err = SWIG_NewPointerObj(ecopy, SWIGTYPE_p_FullError, 1);
|
||||
PyErr_SetObject(SWIG_Python_ExceptionType(SWIGTYPE_p_FullError), err);
|
||||
SWIG_fail;
|
||||
}
|
||||
}
|
||||
|
||||
|
|
@ -87,6 +87,7 @@
|
|||
|
||||
*/
|
||||
%exceptionclass EmptyError;
|
||||
%exceptionclass FullError;
|
||||
|
||||
%exception *::dequeue {
|
||||
try {
|
||||
|
|
@ -94,8 +95,8 @@
|
|||
} catch(EmptyError& e) {
|
||||
EmptyError *ecopy = new EmptyError(e);
|
||||
PyObject *err = SWIG_NewPointerObj(ecopy, SWIGTYPE_p_EmptyError, 1);
|
||||
PyErr_SetObject((PyObject *) SWIGTYPE_p_EmptyError->clientdata, err);
|
||||
return NULL;
|
||||
PyErr_SetObject(SWIG_Python_ExceptionType(SWIGTYPE_p_EmptyError), err);
|
||||
SWIG_fail;
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue