mirror of
https://github.com/VCMP-SqMod/SqMod.git
synced 2024-11-08 00:37:15 +01:00
Include special handling for POCO exceptions in constructors.
This commit is contained in:
parent
1c15090161
commit
cb9c5019f8
@ -125,6 +125,8 @@ public:
|
||||
SetInstance(vm, 1, ArgFwd<A...>{}.Call(vm, 2, [](HSQUIRRELVM /*vm*/, A... a) -> C * {
|
||||
return new C(a...);
|
||||
}));
|
||||
} catch (const Poco::Exception& e) {
|
||||
return sq_throwerror(vm, e.displayText().c_str());
|
||||
} catch (const std::exception& e) {
|
||||
return sq_throwerror(vm, e.what());
|
||||
} catch (...) {
|
||||
@ -497,6 +499,8 @@ public:
|
||||
SetInstance(vm, 1, ArgFwd<A...>{}.Call(vm, 2, [](HSQUIRRELVM /*vm*/, A... a) -> C * {
|
||||
return new C(a...);
|
||||
}));
|
||||
} catch (const Poco::Exception& e) {
|
||||
return sq_throwerror(vm, e.displayText().c_str());
|
||||
} catch (const std::exception& e) {
|
||||
return sq_throwerror(vm, e.what());
|
||||
} catch (...) {
|
||||
|
Loading…
Reference in New Issue
Block a user