diff options
author | Linus Groh <mail@linusgroh.de> | 2020-05-21 13:41:54 +0100 |
---|---|---|
committer | Andreas Kling <kling@serenityos.org> | 2020-05-21 15:18:08 +0200 |
commit | 4e657c370c0d643364e389dbc8cfd11c1800d540 (patch) | |
tree | 403d6f13c55135fbbbcbb7db98a5fdf1c9188745 /Libraries/LibJS/Interpreter.h | |
parent | 14dffe472180805e1a67ce746f012b87ee92cd79 (diff) | |
download | serenity-4e657c370c0d643364e389dbc8cfd11c1800d540.zip |
LibJS: Make Interpreter::call() this_value a required argument
Right now the default is an empty value, which we accidentally exposed
in set{Interval,Timeout}() by not providing a custom this value, which
should't happen at all. Let's just make it a required argument instead.
Diffstat (limited to 'Libraries/LibJS/Interpreter.h')
-rw-r--r-- | Libraries/LibJS/Interpreter.h | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/Libraries/LibJS/Interpreter.h b/Libraries/LibJS/Interpreter.h index 7f26cd58fe..5757e92fc7 100644 --- a/Libraries/LibJS/Interpreter.h +++ b/Libraries/LibJS/Interpreter.h @@ -104,7 +104,7 @@ public: void enter_scope(const ScopeNode&, ArgumentVector, ScopeType); void exit_scope(const ScopeNode&); - Value call(Function&, Value this_value = {}, Optional<MarkedValueList> arguments = {}); + Value call(Function&, Value this_value, Optional<MarkedValueList> arguments = {}); Value construct(Function&, Function& new_target, Optional<MarkedValueList> arguments = {}); CallFrame& push_call_frame() |