LibJS: Reorder and add missing name & length properties to Built-ins

The specification dicatates that each built-in will have a length and
name property. (defined in that order)
This commit is contained in:
Idan Horowitz
2021-07-08 02:49:53 +03:00
committed by Linus Groh
parent 7e4b0681e1
commit eeb4c1eec9
16 changed files with 32 additions and 29 deletions

View File

@@ -26,9 +26,9 @@ void SetConstructor::initialize(GlobalObject& global_object)
// 24.2.2.1 Set.prototype, https://tc39.es/ecma262/#sec-set.prototype
define_direct_property(vm.names.prototype, global_object.set_prototype(), 0);
define_direct_property(vm.names.length, Value(0), Attribute::Configurable);
define_native_accessor(*vm.well_known_symbol_species(), symbol_species_getter, {}, Attribute::Configurable);
define_direct_property(vm.names.length, Value(0), Attribute::Configurable);
}
SetConstructor::~SetConstructor()