feat: SharedArrayBuffer 最小构造器与载荷生命周期

This commit is contained in:
2026-09-23 12:44:05 +00:00
parent 7457740c36
commit 3d50306853
8 changed files with 121 additions and 7 deletions
+3
View File
@@ -67,6 +67,9 @@ impl Vm {
} else if src_ref.is_array_buffer_obj() {
// 字节缓冲深拷贝到新对象:源 Vec 随 epoch 释放,互不共享。
array_buffer::clone_array_buffer_native(src_ref, dst_ref);
} else if src_ref.is_shared_array_buffer_obj() {
// 字节缓冲深拷贝到新对象:源 Vec 随 epoch 释放,互不共享。
array_buffer::clone_shared_array_buffer_native(src_ref, dst_ref);
} else if src_ref.is_generator_obj() {
// 生成器状态盒深拷贝到新对象:源盒随 epoch 释放,互不共享。
crate::generator::clone_generator_native_with_rewrite(src_ref, dst_ref, |value| {