mirror of
https://github.com/RGBCube/serenity
synced 2025-05-31 13:28:11 +00:00
LibJS: Move Console from Interpreter to GlobalObject
Each JS global object has its own "console", so it makes more sense to store it in GlobalObject. We'll need some smartness later to bundle up console messages from all the different frames that make up a page later, but this works for now.
This commit is contained in:
parent
a9335eea1c
commit
e4bda2e1e7
11 changed files with 55 additions and 50 deletions
|
@ -26,6 +26,7 @@
|
|||
*/
|
||||
|
||||
#include <AK/LogStream.h>
|
||||
#include <LibJS/Console.h>
|
||||
#include <LibJS/Heap/DeferGC.h>
|
||||
#include <LibJS/Runtime/ArrayConstructor.h>
|
||||
#include <LibJS/Runtime/ArrayIteratorPrototype.h>
|
||||
|
@ -68,6 +69,7 @@ namespace JS {
|
|||
|
||||
GlobalObject::GlobalObject()
|
||||
: Object(GlobalObjectTag::Tag)
|
||||
, m_console(make<Console>(*this))
|
||||
{
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue