|
@@ -53,7 +53,7 @@ public:
|
|
auto it = m_prototypes.find(class_name);
|
|
auto it = m_prototypes.find(class_name);
|
|
if (it != m_prototypes.end())
|
|
if (it != m_prototypes.end())
|
|
return *it->value;
|
|
return *it->value;
|
|
- auto& realm = *associated_realm();
|
|
|
|
|
|
+ auto& realm = shape().realm();
|
|
auto* prototype = heap().allocate<T>(realm, realm);
|
|
auto* prototype = heap().allocate<T>(realm, realm);
|
|
m_prototypes.set(class_name, prototype);
|
|
m_prototypes.set(class_name, prototype);
|
|
return *prototype;
|
|
return *prototype;
|
|
@@ -65,7 +65,7 @@ public:
|
|
auto it = m_constructors.find(class_name);
|
|
auto it = m_constructors.find(class_name);
|
|
if (it != m_constructors.end())
|
|
if (it != m_constructors.end())
|
|
return *it->value;
|
|
return *it->value;
|
|
- auto& realm = *associated_realm();
|
|
|
|
|
|
+ auto& realm = shape().realm();
|
|
auto* constructor = heap().allocate<T>(realm, realm);
|
|
auto* constructor = heap().allocate<T>(realm, realm);
|
|
m_constructors.set(class_name, constructor);
|
|
m_constructors.set(class_name, constructor);
|
|
define_direct_property(class_name, JS::Value(constructor), JS::Attribute::Writable | JS::Attribute::Configurable);
|
|
define_direct_property(class_name, JS::Value(constructor), JS::Attribute::Writable | JS::Attribute::Configurable);
|