1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-05-20 13:55:08 +00:00

LibJS: Use Identifier to represent name of FunctionNode

This commit is contained in:
Aliaksandr Kalenik 2023-07-02 00:35:51 +03:00 committed by Andreas Kling
parent 380abddf3c
commit a6cdb1655b
4 changed files with 38 additions and 38 deletions

View file

@ -534,7 +534,7 @@ ThrowCompletionOr<void> ECMAScriptFunctionObject::function_declaration_instantia
// NOTE: Due to the use of MUST with `create_mutable_binding` and `initialize_binding` below,
// an exception should not result from `for_each_function_hoistable_with_annexB_extension`.
MUST(scope_body->for_each_function_hoistable_with_annexB_extension([&](FunctionDeclaration& function_declaration) {
auto& function_name = function_declaration.name();
auto function_name = function_declaration.name();
if (parameter_names.contains(function_name))
return;
// The spec says 'initializedBindings' here but that does not exist and it then adds it to 'instantiatedVarNames' so it probably means 'instantiatedVarNames'.