codegen for C++ exceptions

This commit is contained in:
Zahary Karadjov 2012-06-03 20:37:56 +03:00
commit bb850aafec
3 changed files with 80 additions and 65 deletions

View file

@ -281,6 +281,13 @@ static unsigned long nimInf[2]={0xffffffff, 0x7fffffff};
# endif
# define NIM_BOOL bool
# define NIM_NIL 0
struct NimException
{
NimException(struct E_Base* exp, const char* msg): exp(exp), msg(msg) {}
struct E_Base* exp;
const char* msg;
};
#else
# ifdef bool
# define NIM_BOOL bool