mirror of
https://github.com/LadybirdBrowser/ladybird
synced 2026-04-27 10:07:15 +02:00
LibJS: Avoid a FlyString copy in ECMAScriptFunctionObject
This commit is contained in:
Notes:
sideshowbarker
2024-07-18 02:56:06 +09:00
Author: https://github.com/awesomekling Commit: https://github.com/SerenityOS/serenity/commit/70e25deea3d
@@ -177,7 +177,7 @@ ThrowCompletionOr<void> ECMAScriptFunctionObject::function_declaration_instantia
|
||||
functions_to_initialize.append(function);
|
||||
});
|
||||
|
||||
auto arguments_name = vm.names.arguments.as_string();
|
||||
auto const& arguments_name = vm.names.arguments.as_string();
|
||||
|
||||
if (!has_parameter_expressions && function_names.contains(arguments_name))
|
||||
arguments_object_needed = false;
|
||||
|
||||
Reference in New Issue
Block a user