MCPcopy Create free account
hub / github.com/GaijinEntertainment/daScript / das_throw

Function das_throw

src/simulate/runtime_string.cpp:21–28  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

19 DAS_THREAD_LOCAL(string) g_throwMsg;
20
21 void das_throw(const char * msg) {
22 if ( *g_throwBuf ) {
23 *g_throwMsg = msg;
24 longjmp(**g_throwBuf,1);
25 } else {
26 DAS_FATAL_ERROR("unhanded das_throw, %s\n", msg);
27 }
28 }
29
30 void das_trycatch(callable<void()> tryBody, callable<void(const char * msg)> catchBody) {
31 // re-entrant: save/restore the outer frame so das_trycatch can nest (e.g. a fmt

Callers 2

daslang_hash_mapClass · 0.85

Calls 2

dasExceptionClass · 0.85
LineInfoClass · 0.70

Tested by

no test coverage detected