diff --git a/src/module_wrap.cc b/src/module_wrap.cc index 742f3960c881b9..9135dd1de08839 100644 --- a/src/module_wrap.cc +++ b/src/module_wrap.cc @@ -35,6 +35,7 @@ using v8::IntegrityLevel; using v8::Isolate; using v8::Local; using v8::MaybeLocal; +using v8::MemorySpan; using v8::MicrotaskQueue; using v8::Module; using v8::ModuleRequest; @@ -170,8 +171,10 @@ void ModuleWrap::New(const FunctionCallbackInfo& args) { export_names[i] = export_name_val.As(); } - module = Module::CreateSyntheticModule(isolate, url, export_names, - SyntheticModuleEvaluationStepsCallback); + const MemorySpan> span(export_names.begin(), + export_names.size()); + module = Module::CreateSyntheticModule( + isolate, url, span, SyntheticModuleEvaluationStepsCallback); } else { ScriptCompiler::CachedData* cached_data = nullptr; if (!args[5]->IsUndefined()) {