mirror of
https://github.com/fergalmoran/ladybird.git
synced 2026-01-03 15:16:14 +00:00
LibJS+LibWeb: Pass prototype to Object constructor
Everyone who constructs an Object must now pass a prototype object when applicable. There's still a fair amount of code that passes something fetched from the Interpreter, but this brings us closer to being able to detach prototypes from Interpreter eventually.
This commit is contained in:
@@ -38,7 +38,8 @@ Date* Date::create(GlobalObject& global_object, Core::DateTime datetime, u16 mil
|
||||
}
|
||||
|
||||
Date::Date(Core::DateTime datetime, u16 milliseconds, Object& prototype)
|
||||
: m_datetime(datetime)
|
||||
: Object(&prototype)
|
||||
, m_datetime(datetime)
|
||||
, m_milliseconds(milliseconds)
|
||||
{
|
||||
set_prototype(&prototype);
|
||||
|
||||
Reference in New Issue
Block a user