1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-05-31 13:38:11 +00:00

LibJS: Interpreter::this_value() => this_value(GlobalObject&)

Once the Interpreter has no global object attached to it, we have to
provide it everywhere.
This commit is contained in:
Andreas Kling 2020-06-08 21:10:22 +02:00
parent 25f2a29d84
commit 053863f35e
25 changed files with 78 additions and 73 deletions

View file

@ -50,7 +50,7 @@ Value BoundFunction::call(Interpreter& interpreter)
Value BoundFunction::construct(Interpreter& interpreter)
{
if (auto this_value = interpreter.this_value(); m_constructor_prototype && this_value.is_object()) {
if (auto this_value = interpreter.this_value(global_object()); m_constructor_prototype && this_value.is_object()) {
this_value.as_object().set_prototype(m_constructor_prototype);
if (interpreter.exception())
return {};