mirror of
https://github.com/pjh456/OxideJS.git
synced 2026-10-23 18:21:13 +08:00
fix: 越界增长置洞循环改迭代器消除 clippy 告警
This commit is contained in:
@@ -454,8 +454,8 @@ impl JsObject {
|
||||
// pos 槽随后覆盖写,hole 标记由 clear_hole_marker 清除。
|
||||
if old < pos {
|
||||
let meta = self.ensure_array_elements_meta();
|
||||
for idx in old..pos {
|
||||
meta[idx] = Some(PropMetaEntry::hole());
|
||||
for entry in meta.iter_mut().take(pos).skip(old) {
|
||||
*entry = Some(PropMetaEntry::hole());
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user