static bool RequestInterruptCallback(JSContext *cx, unsigned argc, jsval *vp) { JS::CallArgs args = JS::CallArgsFromVp(argc, vp); if (!sRemain--) JS_RequestInterruptCallback(JS_GetRuntime(cx)); args.rval().setUndefined(); return true; }
void MozJSImplScope::gc() { _pendingGC.store(true); JS_RequestInterruptCallback(_runtime); }