mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-07-30 04:39:06 +00:00
LibJS: Remove GlobalObject parameter from native functions
This commit is contained in:
parent
7b990c27a1
commit
b465f46e00
Notes:
sideshowbarker
2024-07-17 07:53:01 +09:00
Author: https://github.com/linusg
Commit: b465f46e00
Pull-request: https://github.com/SerenityOS/serenity/pull/14973
Reviewed-by: https://github.com/davidot ✅
77 changed files with 240 additions and 215 deletions
|
@ -718,8 +718,8 @@ ThrowCompletionOr<void> GetObjectPropertyIterator::execute_impl(Bytecode::Interp
|
|||
.iterator = object,
|
||||
.next_method = NativeFunction::create(
|
||||
interpreter.realm(),
|
||||
[seen_items = HashTable<PropertyKey>(), items = move(properties)](VM& vm, GlobalObject& global_object) mutable -> ThrowCompletionOr<Value> {
|
||||
auto& realm = *global_object.associated_realm();
|
||||
[seen_items = HashTable<PropertyKey>(), items = move(properties)](VM& vm) mutable -> ThrowCompletionOr<Value> {
|
||||
auto& realm = *vm.current_realm();
|
||||
auto iterated_object_value = vm.this_value();
|
||||
if (!iterated_object_value.is_object())
|
||||
return vm.throw_completion<InternalError>("Invalid state for GetObjectPropertyIterator.next");
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue