]> git.kaiwu.me - quickjs.git/commitdiff
Expose `JS_SetUncatchableError()` (#262)
authorKasper Isager Dalsgarð <kasperisager@hey.com>
Thu, 9 May 2024 10:45:47 +0000 (12:45 +0200)
committerGitHub <noreply@github.com>
Thu, 9 May 2024 10:45:47 +0000 (12:45 +0200)
* Expose `JS_SetUncatchableError()`

* Remove unnecessary `JS_SetUncatchableError` declaration

quickjs.c
quickjs.h

index bbba0050ff1b4687b47a345d177c1324fde05844..fd2edd8536c5a1d2a90f1959327672982f42832f 100644 (file)
--- a/quickjs.c
+++ b/quickjs.c
@@ -1276,7 +1276,6 @@ static JSValue js_module_ns_autoinit(JSContext *ctx, JSObject *p, JSAtom atom,
                                  void *opaque);
 static JSValue JS_InstantiateFunctionListItem2(JSContext *ctx, JSObject *p,
                                                JSAtom atom, void *opaque);
-void JS_SetUncatchableError(JSContext *ctx, JSValueConst val, BOOL flag);
 static JSValue js_object_groupBy(JSContext *ctx, JSValueConst this_val,
                                  int argc, JSValueConst *argv, int is_map);
 
index 8e938873503d01748056c035add3ea18705c84d9..a3348a581f6b7643258cdbb248a1b44e114f1c75 100644 (file)
--- a/quickjs.h
+++ b/quickjs.h
@@ -635,6 +635,7 @@ JSValue JS_Throw(JSContext *ctx, JSValue obj);
 JSValue JS_GetException(JSContext *ctx);
 JS_BOOL JS_HasException(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, ...);