LibJS: Add the same Object::invoke() overloads as VM::call()

This commit is contained in:
Linus Groh
2021-03-14 12:01:18 +01:00
committed by Andreas Kling
parent 6cf8e3c980
commit 6d2d8d091f
2 changed files with 23 additions and 2 deletions

View File

@@ -883,7 +883,7 @@ Value Object::ordinary_to_primitive(Value::PreferredType preferred_type) const
return {};
}
Value Object::invoke(const StringOrSymbol& property_name, Optional<MarkedValueList> arguments)
Value Object::invoke_internal(const StringOrSymbol& property_name, Optional<MarkedValueList> arguments)
{
auto& vm = this->vm();
auto property = get(property_name).value_or(js_undefined());