mirror of
https://github.com/RGBCube/serenity
synced 2025-05-28 05:25:09 +00:00
LibJS: Convert bind_this_value() to ThrowCompletionOr
Also add spec step comments to it while we're here.
This commit is contained in:
parent
0aa24f4ce5
commit
617d3cd3d3
4 changed files with 16 additions and 11 deletions
|
@ -656,7 +656,7 @@ void ECMAScriptFunctionObject::ordinary_call_bind_this(ExecutionContext& callee_
|
|||
// 7. Assert: localEnv is a function Environment Record.
|
||||
// 8. Assert: The next step never returns an abrupt completion because localEnv.[[ThisBindingStatus]] is not initialized.
|
||||
// 9. Return localEnv.BindThisValue(thisValue).
|
||||
verify_cast<FunctionEnvironment>(local_env)->bind_this_value(global_object(), this_value);
|
||||
MUST(verify_cast<FunctionEnvironment>(local_env)->bind_this_value(global_object(), this_value));
|
||||
}
|
||||
|
||||
// 10.2.1.4 OrdinaryCallEvaluateBody ( F, argumentsList ), https://tc39.es/ecma262/#sec-ordinarycallevaluatebody
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue