1
0
mirror of https://github.com/VCMP-SqMod/SqMod.git synced 2025-06-15 22:57:12 +02:00

Catch exceptions during server callbacks.

Allow routines to safely terminate routines during execution.
Various other fixes and improvements.
This commit is contained in:
Sandu Liviu Catalin
2016-03-12 08:47:50 +02:00
parent d58099461a
commit d2f3da1747
4 changed files with 1021 additions and 264 deletions

View File

@ -51,6 +51,15 @@ template <> struct NumLimit< long double > { static const long double Min, Max;
*/
struct StackGuard
{
/* --------------------------------------------------------------------------------------------
* Default constructor.
*/
StackGuard()
: m_Top(sq_gettop(DefaultVM::Get())), m_VM(DefaultVM::Get())
{
/* ... */
}
/* --------------------------------------------------------------------------------------------
* Base constructor.
*/