feat: 实现 Object.getOwnPropertyDescriptors 内建

This commit is contained in:
2026-09-20 20:45:15 +00:00
parent d750d4a2b5
commit 4a8894a560
5 changed files with 172 additions and 46 deletions
+1
View File
@@ -28,6 +28,7 @@ impl BuiltinWorld {
("is", methods.is, 2),
("defineProperty", methods.define_property, 3),
("getOwnPropertyDescriptor", methods.get_own_property_descriptor, 2),
("getOwnPropertyDescriptors", methods.get_own_property_descriptors, 1),
("freeze", methods.freeze, 1),
("seal", methods.seal, 1),
("preventExtensions", methods.prevent_extensions, 1),
@@ -8,6 +8,7 @@ pub struct ObjectMethods {
pub is: *const (),
pub define_property: *const (),
pub get_own_property_descriptor: *const (),
pub get_own_property_descriptors: *const (),
pub freeze: *const (),
pub seal: *const (),
pub prevent_extensions: *const (),