Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

use with_capacity to reduce re-allocations fixes #3896 #3961

Open
wants to merge 6 commits into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion core/engine/src/builtins/array/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -108,7 +108,7 @@ impl IntrinsicObject for Array {

let unscopables_object = Self::unscopables_object();

BuiltInBuilder::from_standard_constructor::<Self>(realm)
BuiltInBuilder::from_standard_constructor::<Self>(realm, 41, 5)
// Static Methods
.static_method(Self::from, js_string!("from"), 1)
.static_method(Self::is_array, js_string!("isArray"), 1)
Expand Down
2 changes: 1 addition & 1 deletion core/engine/src/builtins/array_buffer/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -312,7 +312,7 @@ impl IntrinsicObject for ArrayBuffer {
.name(js_string!("get detached"))
.build();

let builder = BuiltInBuilder::from_standard_constructor::<Self>(realm)
let builder = BuiltInBuilder::from_standard_constructor::<Self>(realm, 9, 2)
.static_accessor(
JsSymbol::species(),
Some(get_species),
Expand Down
2 changes: 1 addition & 1 deletion core/engine/src/builtins/array_buffer/shared.rs
Original file line number Diff line number Diff line change
Expand Up @@ -109,7 +109,7 @@ impl IntrinsicObject for SharedArrayBuffer {
.name(js_string!("get maxByteLength"))
.build();

BuiltInBuilder::from_standard_constructor::<Self>(realm)
BuiltInBuilder::from_standard_constructor::<Self>(realm, 6, 1)
.static_accessor(
JsSymbol::species(),
Some(get_species),
Expand Down
2 changes: 1 addition & 1 deletion core/engine/src/builtins/async_function/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ impl IntrinsicObject for AsyncFunction {
fn init(realm: &Realm) {
let _timer = Profiler::global().start_event(std::any::type_name::<Self>(), "init");

BuiltInBuilder::from_standard_constructor::<Self>(realm)
BuiltInBuilder::from_standard_constructor::<Self>(realm, 1, 0)
.prototype(realm.intrinsics().constructors().function().constructor())
.inherits(Some(
realm.intrinsics().constructors().function().prototype(),
Expand Down
2 changes: 1 addition & 1 deletion core/engine/src/builtins/async_generator_function/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ impl IntrinsicObject for AsyncGeneratorFunction {
fn init(realm: &Realm) {
let _timer = Profiler::global().start_event(std::any::type_name::<Self>(), "init");

BuiltInBuilder::from_standard_constructor::<Self>(realm)
BuiltInBuilder::from_standard_constructor::<Self>(realm, 2, 0)
.inherits(Some(
realm.intrinsics().constructors().function().prototype(),
))
Expand Down
2 changes: 1 addition & 1 deletion core/engine/src/builtins/bigint/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ impl IntrinsicObject for BigInt {
fn init(realm: &Realm) {
let _timer = Profiler::global().start_event(std::any::type_name::<Self>(), "init");

BuiltInBuilder::from_standard_constructor::<Self>(realm)
BuiltInBuilder::from_standard_constructor::<Self>(realm, 3, 2)
.method(Self::to_string, js_string!("toString"), 0)
.method(Self::value_of, js_string!("valueOf"), 0)
.static_method(Self::as_int_n, js_string!("asIntN"), 2)
Expand Down
2 changes: 1 addition & 1 deletion core/engine/src/builtins/boolean/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ impl IntrinsicObject for Boolean {
fn init(realm: &Realm) {
let _timer = Profiler::global().start_event(std::any::type_name::<Self>(), "init");

BuiltInBuilder::from_standard_constructor::<Self>(realm)
BuiltInBuilder::from_standard_constructor::<Self>(realm, 2, 0)
.method(Self::to_string, js_string!("toString"), 0)
.method(Self::value_of, js_string!("valueOf"), 0)
.build();
Expand Down
13 changes: 9 additions & 4 deletions core/engine/src/builtins/builder.rs
Original file line number Diff line number Diff line change
Expand Up @@ -524,20 +524,25 @@ impl<'ctx> BuiltInBuilder<'ctx, OrdinaryObject> {
}

impl<'ctx> BuiltInBuilder<'ctx, Callable<Constructor>> {
/// Create a new builder for a constructor function setting the properties ahead of time for optimizations (less reallocations)
pub(crate) fn from_standard_constructor<SC: BuiltInConstructor>(
jasonwilliams marked this conversation as resolved.
Show resolved Hide resolved
realm: &'ctx Realm,
// Sets the minimum storage capacity for the prototype's property table.
num_prototype_properties: usize,
// Sets the minimum storage capacity for the object's property table.
num_own_properties: usize,
) -> BuiltInConstructorWithPrototype<'ctx> {
let constructor = SC::STANDARD_CONSTRUCTOR(realm.intrinsics().constructors());
BuiltInConstructorWithPrototype {
realm,
function: SC::constructor,
name: js_string!(SC::NAME),
length: SC::LENGTH,
object_property_table: PropertyTableInner::default(),
object_storage: Vec::default(),
object_property_table: PropertyTableInner::with_capacity(num_own_properties),
object_storage: Vec::with_capacity(num_own_properties),
object: constructor.constructor(),
prototype_property_table: PropertyTableInner::default(),
prototype_storage: Vec::default(),
prototype_property_table: PropertyTableInner::with_capacity(num_prototype_properties),
prototype_storage: Vec::with_capacity(num_prototype_properties),
prototype: constructor.prototype(),
__proto__: Some(realm.intrinsics().constructors().function().prototype()),
inherits: Some(realm.intrinsics().constructors().object().prototype()),
Expand Down
2 changes: 1 addition & 1 deletion core/engine/src/builtins/dataview/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -109,7 +109,7 @@ impl IntrinsicObject for DataView {
.name(js_string!("get byteOffset"))
.build();

BuiltInBuilder::from_standard_constructor::<Self>(realm)
BuiltInBuilder::from_standard_constructor::<Self>(realm, 24, 0)
.accessor(
js_string!("buffer"),
Some(get_buffer),
Expand Down
2 changes: 1 addition & 1 deletion core/engine/src/builtins/date/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,7 @@ impl IntrinsicObject for Date {
.length(1)
.build();

BuiltInBuilder::from_standard_constructor::<Self>(realm)
BuiltInBuilder::from_standard_constructor::<Self>(realm, 47, 3)
.static_method(Self::now, js_string!("now"), 0)
.static_method(Self::parse, js_string!("parse"), 1)
.static_method(Self::utc, js_string!("UTC"), 7)
Expand Down
2 changes: 1 addition & 1 deletion core/engine/src/builtins/error/aggregate.rs
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ impl IntrinsicObject for AggregateError {
let _timer = Profiler::global().start_event(std::any::type_name::<Self>(), "init");

let attribute = Attribute::WRITABLE | Attribute::NON_ENUMERABLE | Attribute::CONFIGURABLE;
BuiltInBuilder::from_standard_constructor::<Self>(realm)
BuiltInBuilder::from_standard_constructor::<Self>(realm, 2, 0)
.prototype(realm.intrinsics().constructors().error().constructor())
.inherits(Some(realm.intrinsics().constructors().error().prototype()))
.property(js_str!("name"), Self::NAME, attribute)
Expand Down
2 changes: 1 addition & 1 deletion core/engine/src/builtins/error/eval.rs
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ impl IntrinsicObject for EvalError {
let _timer = Profiler::global().start_event(std::any::type_name::<Self>(), "init");

let attribute = Attribute::WRITABLE | Attribute::NON_ENUMERABLE | Attribute::CONFIGURABLE;
BuiltInBuilder::from_standard_constructor::<Self>(realm)
BuiltInBuilder::from_standard_constructor::<Self>(realm, 2, 0)
.prototype(realm.intrinsics().constructors().error().constructor())
.inherits(Some(realm.intrinsics().constructors().error().prototype()))
.property(js_str!("name"), Self::NAME, attribute)
Expand Down
2 changes: 1 addition & 1 deletion core/engine/src/builtins/error/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -136,7 +136,7 @@ impl IntrinsicObject for Error {
let _timer = Profiler::global().start_event(std::any::type_name::<Self>(), "init");

let attribute = Attribute::WRITABLE | Attribute::NON_ENUMERABLE | Attribute::CONFIGURABLE;
BuiltInBuilder::from_standard_constructor::<Self>(realm)
BuiltInBuilder::from_standard_constructor::<Self>(realm, 2, 0)
.property(js_string!("name"), Self::NAME, attribute)
.property(js_string!("message"), js_string!(), attribute)
.method(Self::to_string, js_string!("toString"), 0)
Expand Down
2 changes: 1 addition & 1 deletion core/engine/src/builtins/error/range.rs
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ impl IntrinsicObject for RangeError {
let _timer = Profiler::global().start_event(std::any::type_name::<Self>(), "init");

let attribute = Attribute::WRITABLE | Attribute::NON_ENUMERABLE | Attribute::CONFIGURABLE;
BuiltInBuilder::from_standard_constructor::<Self>(realm)
BuiltInBuilder::from_standard_constructor::<Self>(realm, 2, 0)
.prototype(realm.intrinsics().constructors().error().constructor())
.inherits(Some(realm.intrinsics().constructors().error().prototype()))
.property(js_str!("name"), Self::NAME, attribute)
Expand Down
2 changes: 1 addition & 1 deletion core/engine/src/builtins/error/reference.rs
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ impl IntrinsicObject for ReferenceError {
let _timer = Profiler::global().start_event(std::any::type_name::<Self>(), "init");

let attribute = Attribute::WRITABLE | Attribute::NON_ENUMERABLE | Attribute::CONFIGURABLE;
BuiltInBuilder::from_standard_constructor::<Self>(realm)
BuiltInBuilder::from_standard_constructor::<Self>(realm, 2, 0)
.prototype(realm.intrinsics().constructors().error().constructor())
.inherits(Some(realm.intrinsics().constructors().error().prototype()))
.property(js_str!("name"), Self::NAME, attribute)
Expand Down
2 changes: 1 addition & 1 deletion core/engine/src/builtins/error/syntax.rs
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ impl IntrinsicObject for SyntaxError {
let _timer = Profiler::global().start_event(std::any::type_name::<Self>(), "init");

let attribute = Attribute::WRITABLE | Attribute::NON_ENUMERABLE | Attribute::CONFIGURABLE;
BuiltInBuilder::from_standard_constructor::<Self>(realm)
BuiltInBuilder::from_standard_constructor::<Self>(realm, 2, 0)
.prototype(realm.intrinsics().constructors().error().constructor())
.inherits(Some(realm.intrinsics().constructors().error().prototype()))
.property(js_str!("name"), Self::NAME, attribute)
Expand Down
2 changes: 1 addition & 1 deletion core/engine/src/builtins/error/type.rs
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ impl IntrinsicObject for TypeError {
let _timer = Profiler::global().start_event(std::any::type_name::<Self>(), "init");

let attribute = Attribute::WRITABLE | Attribute::NON_ENUMERABLE | Attribute::CONFIGURABLE;
BuiltInBuilder::from_standard_constructor::<Self>(realm)
BuiltInBuilder::from_standard_constructor::<Self>(realm, 2, 0)
.prototype(realm.intrinsics().constructors().error().constructor())
.inherits(Some(realm.intrinsics().constructors().error().prototype()))
.property(js_str!("name"), Self::NAME, attribute)
Expand Down
2 changes: 1 addition & 1 deletion core/engine/src/builtins/error/uri.rs
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ impl IntrinsicObject for UriError {
let _timer = Profiler::global().start_event(std::any::type_name::<Self>(), "init");

let attribute = Attribute::WRITABLE | Attribute::NON_ENUMERABLE | Attribute::CONFIGURABLE;
BuiltInBuilder::from_standard_constructor::<Self>(realm)
BuiltInBuilder::from_standard_constructor::<Self>(realm, 2, 0)
.prototype(realm.intrinsics().constructors().error().constructor())
.inherits(Some(realm.intrinsics().constructors().error().prototype()))
.property(js_str!("name"), Self::NAME, attribute)
Expand Down
2 changes: 1 addition & 1 deletion core/engine/src/builtins/function/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -317,7 +317,7 @@ impl IntrinsicObject for BuiltInFunctionObject {

let throw_type_error = realm.intrinsics().objects().throw_type_error();

BuiltInBuilder::from_standard_constructor::<Self>(realm)
BuiltInBuilder::from_standard_constructor::<Self>(realm, 7, 0)
.method(Self::apply, js_string!("apply"), 2)
.method(Self::bind, js_string!("bind"), 1)
.method(Self::call, js_string!("call"), 1)
Expand Down
2 changes: 1 addition & 1 deletion core/engine/src/builtins/generator_function/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ impl IntrinsicObject for GeneratorFunction {
fn init(realm: &Realm) {
let _timer = Profiler::global().start_event(std::any::type_name::<Self>(), "init");

BuiltInBuilder::from_standard_constructor::<Self>(realm)
BuiltInBuilder::from_standard_constructor::<Self>(realm, 2, 0)
.inherits(Some(
realm.intrinsics().constructors().function().prototype(),
))
Expand Down
2 changes: 1 addition & 1 deletion core/engine/src/builtins/intl/collator/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -156,7 +156,7 @@ impl IntrinsicObject for Collator {
.name(js_string!("get compare"))
.build();

BuiltInBuilder::from_standard_constructor::<Self>(realm)
BuiltInBuilder::from_standard_constructor::<Self>(realm, 3, 1)
.static_method(
Self::supported_locales_of,
js_string!("supportedLocalesOf"),
Expand Down
2 changes: 1 addition & 1 deletion core/engine/src/builtins/intl/date_time_format.rs
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,7 @@ impl IntrinsicObject for DateTimeFormat {
fn init(realm: &Realm) {
let _timer = Profiler::global().start_event(std::any::type_name::<Self>(), "init");

BuiltInBuilder::from_standard_constructor::<Self>(realm).build();
BuiltInBuilder::from_standard_constructor::<Self>(realm, 0, 0).build();
}

fn get(intrinsics: &Intrinsics) -> JsObject {
Expand Down
2 changes: 1 addition & 1 deletion core/engine/src/builtins/intl/list_format/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ impl IntrinsicObject for ListFormat {
fn init(realm: &Realm) {
let _timer = Profiler::global().start_event(std::any::type_name::<Self>(), "init");

BuiltInBuilder::from_standard_constructor::<Self>(realm)
BuiltInBuilder::from_standard_constructor::<Self>(realm, 4, 1)
.static_method(
Self::supported_locales_of,
js_string!("supportedLocalesOf"),
Expand Down
2 changes: 1 addition & 1 deletion core/engine/src/builtins/intl/locale/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,7 @@ impl IntrinsicObject for Locale {
.name(js_string!("get region"))
.build();

BuiltInBuilder::from_standard_constructor::<Self>(realm)
BuiltInBuilder::from_standard_constructor::<Self>(realm, 14, 0)
.property(
JsSymbol::to_string_tag(),
js_string!("Intl.Locale"),
Expand Down
2 changes: 1 addition & 1 deletion core/engine/src/builtins/intl/number_format/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -141,7 +141,7 @@ impl IntrinsicObject for NumberFormat {
.name(js_string!("get format"))
.build();

BuiltInBuilder::from_standard_constructor::<Self>(realm)
BuiltInBuilder::from_standard_constructor::<Self>(realm, 3, 1)
.static_method(
Self::supported_locales_of,
js_string!("supportedLocalesOf"),
Expand Down
2 changes: 1 addition & 1 deletion core/engine/src/builtins/intl/plural_rules/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ impl IntrinsicObject for PluralRules {
fn init(realm: &Realm) {
let _timer = Profiler::global().start_event(std::any::type_name::<Self>(), "init");

BuiltInBuilder::from_standard_constructor::<Self>(realm)
BuiltInBuilder::from_standard_constructor::<Self>(realm, 4, 1)
.static_method(
Self::supported_locales_of,
js_string!("supportedLocalesOf"),
Expand Down
2 changes: 1 addition & 1 deletion core/engine/src/builtins/intl/segmenter/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,7 @@ impl IntrinsicObject for Segmenter {
fn init(realm: &Realm) {
let _timer = Profiler::global().start_event(std::any::type_name::<Self>(), "init");

BuiltInBuilder::from_standard_constructor::<Self>(realm)
BuiltInBuilder::from_standard_constructor::<Self>(realm, 3, 1)
.static_method(
Self::supported_locales_of,
js_string!("supportedLocalesOf"),
Expand Down
2 changes: 1 addition & 1 deletion core/engine/src/builtins/map/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ impl IntrinsicObject for Map {
.name(js_string!("entries"))
.build();

BuiltInBuilder::from_standard_constructor::<Self>(realm)
BuiltInBuilder::from_standard_constructor::<Self>(realm, 11, 2)
.static_method(Self::group_by, js_string!("groupBy"), 2)
.static_accessor(
JsSymbol::species(),
Expand Down
2 changes: 1 addition & 1 deletion core/engine/src/builtins/number/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ impl IntrinsicObject for Number {

let attribute = Attribute::READONLY | Attribute::NON_ENUMERABLE | Attribute::PERMANENT;

BuiltInBuilder::from_standard_constructor::<Self>(realm)
BuiltInBuilder::from_standard_constructor::<Self>(realm, 6, 14)
.static_property(js_string!("EPSILON"), f64::EPSILON, attribute)
.static_property(
js_string!("MAX_SAFE_INTEGER"),
Expand Down
2 changes: 1 addition & 1 deletion core/engine/src/builtins/object/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@ impl IntrinsicObject for OrdinaryObject {
.name(js_string!("set __proto__"))
.build();

BuiltInBuilder::from_standard_constructor::<Self>(realm)
BuiltInBuilder::from_standard_constructor::<Self>(realm, 11, 23)
.inherits(None)
.accessor(
js_string!("__proto__"),
Expand Down
2 changes: 1 addition & 1 deletion core/engine/src/builtins/promise/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -340,7 +340,7 @@ impl IntrinsicObject for Promise {
.name(js_string!("get [Symbol.species]"))
.build();

BuiltInBuilder::from_standard_constructor::<Self>(realm)
BuiltInBuilder::from_standard_constructor::<Self>(realm, 4, 9)
.static_method(Self::all, js_string!("all"), 1)
.static_method(Self::all_settled, js_string!("allSettled"), 1)
.static_method(Self::any, js_string!("any"), 1)
Expand Down
2 changes: 1 addition & 1 deletion core/engine/src/builtins/proxy/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -90,7 +90,7 @@ impl IntrinsicObject for Proxy {
fn init(realm: &Realm) {
let _timer = Profiler::global().start_event(std::any::type_name::<Self>(), "init");

BuiltInBuilder::from_standard_constructor::<Self>(realm)
BuiltInBuilder::from_standard_constructor::<Self>(realm, 0, 1)
.static_method(Self::revocable, js_string!("revocable"), 2)
.build_without_prototype();
}
Expand Down
2 changes: 1 addition & 1 deletion core/engine/src/builtins/regexp/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -88,7 +88,7 @@ impl IntrinsicObject for RegExp {
let get_source = BuiltInBuilder::callable(realm, Self::get_source)
.name(js_string!("get source"))
.build();
let regexp = BuiltInBuilder::from_standard_constructor::<Self>(realm)
let regexp = BuiltInBuilder::from_standard_constructor::<Self>(realm, 19, 1)
.static_accessor(
JsSymbol::species(),
Some(get_species),
Expand Down
2 changes: 1 addition & 1 deletion core/engine/src/builtins/set/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ impl IntrinsicObject for Set {
.name(js_string!("values"))
.build();

BuiltInBuilder::from_standard_constructor::<Self>(realm)
BuiltInBuilder::from_standard_constructor::<Self>(realm, 11, 1)
.static_accessor(
JsSymbol::species(),
Some(get_species),
Expand Down
2 changes: 1 addition & 1 deletion core/engine/src/builtins/string/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -98,7 +98,7 @@ impl IntrinsicObject for String {
let trim_right = trim_end.clone();

let attribute = Attribute::READONLY | Attribute::NON_ENUMERABLE | Attribute::PERMANENT;
let builder = BuiltInBuilder::from_standard_constructor::<Self>(realm)
let builder = BuiltInBuilder::from_standard_constructor::<Self>(realm, 36, 3)
.property(js_string!("length"), 0, attribute)
.property(
js_string!("trimStart"),
Expand Down
2 changes: 1 addition & 1 deletion core/engine/src/builtins/symbol/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -122,7 +122,7 @@ impl IntrinsicObject for Symbol {
.name(js_string!("get description"))
.build();

BuiltInBuilder::from_standard_constructor::<Self>(realm)
BuiltInBuilder::from_standard_constructor::<Self>(realm, 5, 15)
.static_method(Self::for_, js_string!("for"), 1)
.static_method(Self::key_for, js_string!("keyFor"), 1)
.static_property(
Expand Down
2 changes: 1 addition & 1 deletion core/engine/src/builtins/temporal/duration/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -103,7 +103,7 @@ impl IntrinsicObject for Duration {
.name(js_string!("get blank"))
.build();

BuiltInBuilder::from_standard_constructor::<Self>(realm)
BuiltInBuilder::from_standard_constructor::<Self>(realm, 22, 1)
.property(
JsSymbol::to_string_tag(),
StaticJsStrings::DURATION_TAG,
Expand Down
2 changes: 1 addition & 1 deletion core/engine/src/builtins/temporal/instant/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,7 @@ impl IntrinsicObject for Instant {
.name(js_string!("get epochNanoseconds"))
.build();

BuiltInBuilder::from_standard_constructor::<Self>(realm)
BuiltInBuilder::from_standard_constructor::<Self>(realm, 13, 4)
.property(
JsSymbol::to_string_tag(),
StaticJsStrings::INSTANT_TAG,
Expand Down
2 changes: 1 addition & 1 deletion core/engine/src/builtins/temporal/plain_date/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -123,7 +123,7 @@ impl IntrinsicObject for PlainDate {
.name(js_string!("get inLeapYear"))
.build();

BuiltInBuilder::from_standard_constructor::<Self>(realm)
BuiltInBuilder::from_standard_constructor::<Self>(realm, 26, 2)
.property(
JsSymbol::to_string_tag(),
StaticJsStrings::PLAIN_DATE_TAG,
Expand Down
2 changes: 1 addition & 1 deletion core/engine/src/builtins/temporal/plain_date_time/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -155,7 +155,7 @@ impl IntrinsicObject for PlainDateTime {
.name(js_string!("get inLeapYear"))
.build();

BuiltInBuilder::from_standard_constructor::<Self>(realm)
BuiltInBuilder::from_standard_constructor::<Self>(realm, 29, 2)
.property(
JsSymbol::to_string_tag(),
StaticJsStrings::PLAIN_DATETIME_TAG,
Expand Down
2 changes: 1 addition & 1 deletion core/engine/src/builtins/temporal/plain_month_day/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -149,7 +149,7 @@ impl IntrinsicObject for PlainMonthDay {
.name(js_string!("get calendarId"))
.build();

BuiltInBuilder::from_standard_constructor::<Self>(realm)
BuiltInBuilder::from_standard_constructor::<Self>(realm, 5, 1)
.property(
JsSymbol::to_string_tag(),
StaticJsStrings::PLAIN_MD_TAG,
Expand Down
Loading
Loading