feat(typedarray): 实现整数索引读取与 for-of 迭代(get_iterator 支持)

This commit is contained in:
爱特每羊队
2026-08-07 18:10:19 +08:00
parent 33690fb803
commit eebee1b624
3 changed files with 51 additions and 1 deletions
+5
View File
@@ -53,6 +53,11 @@ impl Vm {
}
}
}
if obj.is_typed_array_obj() {
if let Some(index) = self.array_index_from_property_key(prop_name_si) {
return oxide_builtins::typed_array::typed_array_element_get(self, obj, index);
}
}
if let Some(pos) = self.get_own_property_slot(obj, prop_name_si) {
if let Some(meta) = obj.prop_meta_at(pos) {
if meta.is_accessor {