Index: src/builtins.cc |
diff --git a/src/builtins.cc b/src/builtins.cc |
index ed07d5d089101311f1f90c61b396e6ba61de64ca..3c19810bdc112a7779c0c9997cd7c6d030cae975 100644 |
--- a/src/builtins.cc |
+++ b/src/builtins.cc |
@@ -4571,9 +4571,11 @@ MUST_USE_RESULT MaybeHandle<Object> HandleApiCallHelper( |
} |
Handle<ObjectTemplateInfo> instance_template( |
ObjectTemplateInfo::cast(fun_data->instance_template()), isolate); |
- ASSIGN_RETURN_ON_EXCEPTION(isolate, receiver, |
- ApiNatives::InstantiateObject(instance_template), |
- Object); |
+ ASSIGN_RETURN_ON_EXCEPTION( |
+ isolate, receiver, |
+ ApiNatives::InstantiateObject(instance_template, |
+ Handle<JSReceiver>::cast(new_target)), |
+ Object); |
args[0] = *receiver; |
DCHECK_EQ(*receiver, *args.receiver()); |
} else { |