1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-07-27 07:37:46 +00:00

LibJS: Move the GlobalEnvironment from GlobalObject to Realm

This is where the spec wants to have it. Requires a couple of hacks as
currently everything that needs a Realm actually has a GlobalObject, so
we need to go via the Interpreter.
This commit is contained in:
Linus Groh 2021-09-11 20:27:36 +01:00
parent 1e79934acf
commit f29a82dd84
6 changed files with 13 additions and 16 deletions

View file

@ -21,8 +21,6 @@ public:
virtual ~GlobalObject() override;
GlobalEnvironment& environment() { return *m_environment; }
Console& console() { return *m_console; }
Shape* empty_object_shape() { return m_empty_object_shape; }
@ -100,8 +98,6 @@ private:
// Not included in JS_ENUMERATE_NATIVE_OBJECTS due to missing distinct constructor
GeneratorObjectPrototype* m_generator_object_prototype { nullptr };
GlobalEnvironment* m_environment { nullptr };
FunctionObject* m_array_prototype_values_function { nullptr };
FunctionObject* m_eval_function { nullptr };
FunctionObject* m_temporal_time_zone_prototype_get_offset_nanoseconds_for_function { nullptr };