[pykd] added : lost dbgexcept.cpp file

git-svn-id: https://pykd.svn.codeplex.com/svn@65724 9b283d60-5439-405e-af05-b73fd8c4d996
This commit is contained in:
SND\kernelnet_cp 2011-05-23 09:36:01 +00:00
parent a1f173a193
commit c90d280a94

41
pykd/dbgexcept.cpp Normal file
View File

@ -0,0 +1,41 @@
#include "stdafx.h"
#include "dbgexcept.h"
/////////////////////////////////////////////////////////////////////////////////
// òèïû èñêëþ÷åíèé
PyObject *baseExceptionType = NULL;
PyObject *typeExceptionType = NULL;
PyObject *memoryExceptionType = NULL;
/////////////////////////////////////////////////////////////////////////////////
void DbgException::exceptionTranslate( const DbgException &e )
{
boost::python::object pyExcept(e);
PyErr_SetObject( baseExceptionType, pyExcept.ptr());
}
/////////////////////////////////////////////////////////////////////////////////
void TypeException::exceptionTranslate( const TypeException &e )
{
boost::python::object pyExcept(e);
PyErr_SetObject( typeExceptionType, pyExcept.ptr());
}
/////////////////////////////////////////////////////////////////////////////////
void MemoryException::translate( const MemoryException &e )
{
boost::python::object pyExcept(e);
PyErr_SetObject( memoryExceptionType, pyExcept.ptr());
}
/////////////////////////////////////////////////////////////////////////////////