Skip to content

Commit 4782818

Browse files
committed
src: use non-deprecated version of CreateSyntheticModule
Refs: v8/v8@8ff02b7 PR-URL: #50115 Reviewed-By: Rafael Gonzaga <rafael.nunu@hotmail.com> Reviewed-By: Michael Dawson <midawson@redhat.com>
1 parent 941cef5 commit 4782818

File tree

1 file changed

+5
-2
lines changed

1 file changed

+5
-2
lines changed

src/module_wrap.cc

+5-2
Original file line numberDiff line numberDiff line change
@@ -35,6 +35,7 @@ using v8::IntegrityLevel;
3535
using v8::Isolate;
3636
using v8::Local;
3737
using v8::MaybeLocal;
38+
using v8::MemorySpan;
3839
using v8::MicrotaskQueue;
3940
using v8::Module;
4041
using v8::ModuleRequest;
@@ -170,8 +171,10 @@ void ModuleWrap::New(const FunctionCallbackInfo<Value>& args) {
170171
export_names[i] = export_name_val.As<String>();
171172
}
172173

173-
module = Module::CreateSyntheticModule(isolate, url, export_names,
174-
SyntheticModuleEvaluationStepsCallback);
174+
const MemorySpan<const Local<String>> span(export_names.begin(),
175+
export_names.size());
176+
module = Module::CreateSyntheticModule(
177+
isolate, url, span, SyntheticModuleEvaluationStepsCallback);
175178
} else {
176179
ScriptCompiler::CachedData* cached_data = nullptr;
177180
if (!args[5]->IsUndefined()) {

0 commit comments

Comments
 (0)