mirror of
https://github.com/fergalmoran/ladybird.git
synced 2025-12-25 19:04:58 +00:00
LibJS: Make Function::call() not require an Interpreter&
This makes a difference inside ScriptFunction::call(), which will now instantiate a temporary Interpreter if one is not attached to the VM.
This commit is contained in:
@@ -64,14 +64,14 @@ ObjectConstructor::~ObjectConstructor()
|
||||
{
|
||||
}
|
||||
|
||||
Value ObjectConstructor::call(Interpreter&)
|
||||
Value ObjectConstructor::call()
|
||||
{
|
||||
return Object::create_empty(global_object());
|
||||
}
|
||||
|
||||
Value ObjectConstructor::construct(Interpreter& interpreter, Function&)
|
||||
Value ObjectConstructor::construct(Interpreter&, Function&)
|
||||
{
|
||||
return call(interpreter);
|
||||
return call();
|
||||
}
|
||||
|
||||
JS_DEFINE_NATIVE_FUNCTION(ObjectConstructor::get_own_property_names)
|
||||
|
||||
Reference in New Issue
Block a user