diff options
author | Andreas Kling <kling@serenityos.org> | 2021-10-04 22:53:44 +0200 |
---|---|---|
committer | Andreas Kling <kling@serenityos.org> | 2021-10-04 22:54:50 +0200 |
commit | d872f0d503399289332e8d9e7d9c515a5156e826 (patch) | |
tree | 018048a23ddc6ec5954441c5f97add809fb72ddb /Userland/Libraries/LibJS/Runtime/AbstractOperations.cpp | |
parent | f4180b7269742d4c433381880208e26856809601 (diff) | |
download | serenity-d872f0d503399289332e8d9e7d9c515a5156e826.zip |
LibJS: Avoid an unnecessary String in create_mapped_arguments_object()
Diffstat (limited to 'Userland/Libraries/LibJS/Runtime/AbstractOperations.cpp')
-rw-r--r-- | Userland/Libraries/LibJS/Runtime/AbstractOperations.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/Userland/Libraries/LibJS/Runtime/AbstractOperations.cpp b/Userland/Libraries/LibJS/Runtime/AbstractOperations.cpp index e631359ac1..b6a7e86383 100644 --- a/Userland/Libraries/LibJS/Runtime/AbstractOperations.cpp +++ b/Userland/Libraries/LibJS/Runtime/AbstractOperations.cpp @@ -769,7 +769,7 @@ Object* create_mapped_arguments_object(GlobalObject& global_object, FunctionObje // 2. Let p be MakeArgSetter(name, env). // 3. Perform map.[[DefineOwnProperty]](! ToString(𝔽(index)), PropertyDescriptor { [[Set]]: p, [[Get]]: g, [[Enumerable]]: false, [[Configurable]]: true }). object->parameter_map().define_native_accessor( - String::number(index), + PropertyName { index }, [&environment, name](VM&, GlobalObject& global_object_getter) -> Value { return environment.get_binding_value(global_object_getter, name, false); }, |