MCPcopy Create free account
hub / github.com/buke/quickjs-go / make_obj_error

Function make_obj_error

deps/quickjs/quickjs-libc.c:2988–2999  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

2986#endif // defined(_WIN32)
2987
2988static JSValue make_obj_error(JSContext *ctx,
2989 JSValue obj,
2990 int err)
2991{
2992 JSValue vals[2];
2993
2994 if (JS_IsException(obj))
2995 return obj;
2996 vals[0] = obj;
2997 vals[1] = JS_NewInt32(ctx, err);
2998 return JS_NewArrayFrom(ctx, countof(vals), vals);
2999}
3000
3001static JSValue make_string_error(JSContext *ctx,
3002 const char *buf,

Callers 4

make_string_errorFunction · 0.85
js_os_readdirFunction · 0.85
js_os_mkdstempFunction · 0.85
js_os_statFunction · 0.85

Calls 2

JS_IsExceptionFunction · 0.85
JS_NewInt32Function · 0.85

Tested by

no test coverage detected