mirror of
https://github.com/pjh456/OxideJS.git
synced 2026-10-24 18:51:13 +08:00
refactor: 退役 new_array 死参数与三十四处调用点
This commit is contained in:
@@ -1201,7 +1201,7 @@ impl Vm {
|
||||
// 时对象地址稳定,缓存指针不失效——分配档不同则首次写入触发搬移,
|
||||
// 缓存旧指针与新实例分叉,同一 site 两次取值将返回不同对象。
|
||||
let mut alloc_session_array = |n: usize| {
|
||||
let clone = JsObject::new_array(oxide_kernel::shape_forge::EMPTY_SHAPE_ID, proto_val, n, self.epoch.bump());
|
||||
let clone = JsObject::new_array(oxide_kernel::shape_forge::EMPTY_SHAPE_ID, proto_val, n);
|
||||
self.alloc_session_object(clone)
|
||||
};
|
||||
let cooked = alloc_session_array(n);
|
||||
|
||||
Reference in New Issue
Block a user