mirror of
https://github.com/LadybirdBrowser/ladybird
synced 2026-04-27 02:05:07 +02:00
LibJS: Replace GlobalObject with VM in Reference AOs [Part 6/19]
This commit is contained in:
Notes:
sideshowbarker
2024-07-17 08:00:35 +09:00
Author: https://github.com/linusg Commit: https://github.com/SerenityOS/serenity/commit/ae9e031f56 Pull-request: https://github.com/SerenityOS/serenity/pull/14973 Reviewed-by: https://github.com/davidot ✅
@@ -463,9 +463,9 @@ ThrowCompletionOr<void> ECMAScriptFunctionObject::function_declaration_instantia
|
||||
Reference reference = TRY(vm.resolve_binding(param, used_environment));
|
||||
// Here the difference from hasDuplicates is important
|
||||
if (has_duplicates)
|
||||
return reference.put_value(global_object, argument_value);
|
||||
return reference.put_value(vm, argument_value);
|
||||
else
|
||||
return reference.initialize_referenced_binding(global_object, argument_value);
|
||||
return reference.initialize_referenced_binding(vm, argument_value);
|
||||
} else if (IsSame<NonnullRefPtr<BindingPattern> const&, decltype(param)>) {
|
||||
// Here the difference from hasDuplicates is important
|
||||
return vm.binding_initialization(param, argument_value, used_environment, global_object);
|
||||
|
||||
Reference in New Issue
Block a user