Add new.target argument to Promise create (#4606)

JerryScript-DCO-1.0-Signed-off-by: Zoltan Herczeg zherczeg.u-szeged@partner.samsung.com
This commit is contained in:
Zoltan Herczeg
2021-02-24 08:50:05 +01:00
committed by GitHub
parent 5c35370327
commit 1cf2989a64
7 changed files with 18 additions and 35 deletions
@@ -455,7 +455,9 @@ ecma_builtin_promise_dispatch_construct (const ecma_value_t *arguments_list_p, /
return ecma_raise_type_error (ECMA_ERR_MSG ("First parameter must be callable"));
}
return ecma_op_create_promise_object (arguments_list_p[0], ECMA_VALUE_UNDEFINED);
return ecma_op_create_promise_object (arguments_list_p[0],
ECMA_VALUE_UNDEFINED,
JERRY_CONTEXT (current_new_target_p));
} /* ecma_builtin_promise_dispatch_construct */
/**