diff options
| author | bptato <nincsnevem662@gmail.com> | 2024-05-04 19:43:42 +0200 |
|---|---|---|
| committer | bptato <nincsnevem662@gmail.com> | 2024-05-04 20:06:58 +0200 |
| commit | 63442e5f8be17631a91cee352e441f59daa2df0a (patch) | |
| tree | d546f8c0bf6884464ace32f2a083ce5098e064b1 /lib | |
| parent | 970378356d0d7239b332baa37470455391b5e6e4 (diff) | |
| download | chawan-63442e5f8be17631a91cee352e441f59daa2df0a.tar.gz | |
client: make quit() actually quit, misc fixes
* unwind the QJS stack with an uncatchable exception when quit is called
* clean up JS references in JSRuntime free even when the Nim
counterparts are still alive
* simplify some tests
Diffstat (limited to 'lib')
| -rw-r--r-- | lib/quickjs/quickjs.h | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/lib/quickjs/quickjs.h b/lib/quickjs/quickjs.h index 7b6edd1f..89fbca34 100644 --- a/lib/quickjs/quickjs.h +++ b/lib/quickjs/quickjs.h @@ -636,6 +636,7 @@ static inline JS_BOOL JS_IsObject(JSValueConst v) JSValue JS_Throw(JSContext *ctx, JSValue obj); JSValue JS_GetException(JSContext *ctx); JS_BOOL JS_IsError(JSContext *ctx, JSValueConst val); +void JS_SetUncatchableError(JSContext *ctx , JSValueConst val, JS_BOOL flag); void JS_ResetUncatchableError(JSContext *ctx); JSValue JS_NewError(JSContext *ctx); JSValue __js_printf_like(2, 3) JS_ThrowSyntaxError(JSContext *ctx, const char *fmt, ...); |