mirror of
https://github.com/pjh456/OxideJS.git
synced 2026-10-25 03:01:12 +08:00
feat: SAB 原型 slice 完整语义(species 默认 SAB 与结果三检直拷)
This commit is contained in:
@@ -18,16 +18,24 @@ pub fn bind_shared_array_buffer(core: &Arc<KernelCore>, session: &KernelSession,
|
||||
1,
|
||||
);
|
||||
|
||||
// grow 方法(slice 归后续面):growable 缓冲区原地增长,只增不缩。
|
||||
// grow/slice 方法:grow 原地增长(只增不缩);slice 复制字节区间生成
|
||||
// 新 SAB。
|
||||
apply_binding_table(
|
||||
session.builtin_world(),
|
||||
proto,
|
||||
core,
|
||||
&[(
|
||||
"grow",
|
||||
oxide_builtins::array_buffer::shared_array_buffer_grow::<crate::vm::Vm> as *const (),
|
||||
1,
|
||||
)],
|
||||
&[
|
||||
(
|
||||
"grow",
|
||||
oxide_builtins::array_buffer::shared_array_buffer_grow::<crate::vm::Vm> as *const (),
|
||||
1,
|
||||
),
|
||||
(
|
||||
"slice",
|
||||
oxide_builtins::array_buffer::shared_array_buffer_slice::<crate::vm::Vm> as *const (),
|
||||
2,
|
||||
),
|
||||
],
|
||||
);
|
||||
|
||||
// byteLength/maxByteLength 两枚访问器(set 恒 undefined)读载荷字节数 /
|
||||
|
||||
Reference in New Issue
Block a user