diff options
Diffstat (limited to 'Libraries/LibJS/Interpreter.h')
-rw-r--r-- | Libraries/LibJS/Interpreter.h | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/Libraries/LibJS/Interpreter.h b/Libraries/LibJS/Interpreter.h index a4b6a4640f..6897b54018 100644 --- a/Libraries/LibJS/Interpreter.h +++ b/Libraries/LibJS/Interpreter.h @@ -78,7 +78,7 @@ public: static NonnullOwnPtr<Interpreter> create(Args&&... args) { auto interpreter = adopt_own(*new Interpreter); - interpreter->m_global_object = interpreter->heap().allocate<GlobalObjectType>(forward<Args>(args)...); + interpreter->m_global_object = interpreter->heap().allocate_without_global_object<GlobalObjectType>(forward<Args>(args)...); static_cast<GlobalObjectType*>(interpreter->m_global_object)->initialize(); return interpreter; } @@ -173,7 +173,7 @@ public: Value throw_exception(Exception*); Value throw_exception(Value value) { - return throw_exception(heap().allocate<Exception>(value)); + return throw_exception(heap().allocate<Exception>(global_object(), value)); } template<typename T, typename... Args> |