LibJS: Make more Interpreter functions take a GlobalObject&

This commit is contained in:
Andreas Kling 2020-06-08 21:25:16 +02:00
commit 5042e560ef
Notes: sideshowbarker 2024-07-19 05:44:44 +09:00
9 changed files with 47 additions and 47 deletions

View file

@ -347,7 +347,7 @@ bool parse_and_run(JS::Interpreter& interpreter, const StringView& source)
printf("%s\n", hint.characters());
interpreter.throw_exception<JS::SyntaxError>(error.to_string());
} else {
interpreter.run(*program);
interpreter.run(interpreter.global_object(), *program);
}
if (interpreter.exception()) {
@ -820,7 +820,7 @@ int main(int argc, char** argv)
switch (mode) {
case CompleteProperty: {
auto maybe_variable = interpreter->get_variable(variable_name);
auto maybe_variable = interpreter->get_variable(variable_name, interpreter->global_object());
if (maybe_variable.is_empty()) {
maybe_variable = interpreter->global_object().get(FlyString(variable_name));
if (maybe_variable.is_empty())