summaryrefslogtreecommitdiff
path: root/Userland/Libraries/LibJS/Runtime/ECMAScriptFunctionObject.cpp
diff options
context:
space:
mode:
authorLinus Groh <mail@linusgroh.de>2021-10-05 00:04:25 +0100
committerLinus Groh <mail@linusgroh.de>2021-10-05 10:15:14 +0100
commitfcb355f193b6f0a9bb9afe7f5adb116ef0883dd2 (patch)
tree141f96173f97a039d50a2f6a6859102f6cbef962 /Userland/Libraries/LibJS/Runtime/ECMAScriptFunctionObject.cpp
parentb2bded390ac8755e499764dacec9fa51a9404693 (diff)
downloadserenity-fcb355f193b6f0a9bb9afe7f5adb116ef0883dd2.zip
LibJS: Set arguments_object_needed = false if scope_body == nullptr
For obvious reasons.
Diffstat (limited to 'Userland/Libraries/LibJS/Runtime/ECMAScriptFunctionObject.cpp')
-rw-r--r--Userland/Libraries/LibJS/Runtime/ECMAScriptFunctionObject.cpp2
1 files changed, 2 insertions, 0 deletions
diff --git a/Userland/Libraries/LibJS/Runtime/ECMAScriptFunctionObject.cpp b/Userland/Libraries/LibJS/Runtime/ECMAScriptFunctionObject.cpp
index c6112d3813..d0ef282fee 100644
--- a/Userland/Libraries/LibJS/Runtime/ECMAScriptFunctionObject.cpp
+++ b/Userland/Libraries/LibJS/Runtime/ECMAScriptFunctionObject.cpp
@@ -186,6 +186,8 @@ ThrowCompletionOr<void> ECMAScriptFunctionObject::function_declaration_instantia
return IterationDecision::Continue;
});
}
+ } else {
+ arguments_object_needed = false;
}
Environment* environment;