@@ -299,6 +299,10 @@ class UtilsExtension : public IsolateData::SetupGlobalTask {
299299 utils->Set (ToV8String (isolate, " setLogConsoleApiMessageCalls" ),
300300 v8::FunctionTemplate::New (
301301 isolate, &UtilsExtension::SetLogConsoleApiMessageCalls));
302+ utils->Set (
303+ ToV8String (isolate, " setLogMaxAsyncCallStackDepthChanged" ),
304+ v8::FunctionTemplate::New (
305+ isolate, &UtilsExtension::SetLogMaxAsyncCallStackDepthChanged));
302306 utils->Set (ToV8String (isolate, " createContextGroup" ),
303307 v8::FunctionTemplate::New (isolate,
304308 &UtilsExtension::CreateContextGroup));
@@ -485,6 +489,17 @@ class UtilsExtension : public IsolateData::SetupGlobalTask {
485489 args[0 ].As <v8::Boolean>()->Value ());
486490 }
487491
492+ static void SetLogMaxAsyncCallStackDepthChanged (
493+ const v8::FunctionCallbackInfo<v8::Value>& args) {
494+ if (args.Length () != 1 || !args[0 ]->IsBoolean ()) {
495+ fprintf (stderr,
496+ " Internal error: setLogMaxAsyncCallStackDepthChanged(bool)." );
497+ Exit ();
498+ }
499+ backend_runner_->data ()->SetLogMaxAsyncCallStackDepthChanged (
500+ args[0 ].As <v8::Boolean>()->Value ());
501+ }
502+
488503 static void CreateContextGroup (
489504 const v8::FunctionCallbackInfo<v8::Value>& args) {
490505 if (args.Length () != 0 ) {
0 commit comments