summaryrefslogtreecommitdiff
path: root/Libraries/LibJS/Runtime/PropertyName.h
diff options
context:
space:
mode:
authorAndreas Kling <kling@serenityos.org>2020-09-27 18:36:49 +0200
committerAndreas Kling <kling@serenityos.org>2020-09-27 20:26:58 +0200
commit340a115dfe9518eae3d76154fba9092c36526430 (patch)
treeced6db98e45ce6ac110db8e6a2a8ba7d95565cea /Libraries/LibJS/Runtime/PropertyName.h
parent1ff9d33131921d97b5de99496f933bcebeb4faaa (diff)
downloadserenity-340a115dfe9518eae3d76154fba9092c36526430.zip
LibJS: Make native function/property callbacks take VM, not Interpreter
More work on decoupling the general runtime from Interpreter. The goal is becoming clearer. Interpreter should be one possible way to execute code inside a VM. In the future we might have other ways :^)
Diffstat (limited to 'Libraries/LibJS/Runtime/PropertyName.h')
-rw-r--r--Libraries/LibJS/Runtime/PropertyName.h4
1 files changed, 2 insertions, 2 deletions
diff --git a/Libraries/LibJS/Runtime/PropertyName.h b/Libraries/LibJS/Runtime/PropertyName.h
index 9627f2db88..76c25eb9d0 100644
--- a/Libraries/LibJS/Runtime/PropertyName.h
+++ b/Libraries/LibJS/Runtime/PropertyName.h
@@ -40,14 +40,14 @@ public:
Symbol,
};
- static PropertyName from_value(Interpreter& interpreter, Value value)
+ static PropertyName from_value(GlobalObject& global_object, Value value)
{
if (value.is_symbol())
return &value.as_symbol();
if (value.is_number())
return value.as_i32();
if (!value.is_empty())
- return value.to_string(interpreter);
+ return value.to_string(global_object);
return {};
}