fix: 修复 oxide_builtins 整数溢出 panic 点与安全转换

This commit is contained in:
2026-09-21 14:11:20 +00:00
parent b4d281d109
commit fea24b6d26
19 changed files with 291 additions and 91 deletions
+1 -1
View File
@@ -511,7 +511,7 @@ fn low64<H: VmHost>(vm: &mut H, val: JsValue) -> u64 {
let v = vm.bigint_value(val);
(v & (BigInt::from(u64::MAX)))
.to_u64()
.expect("与 u64::MAX 掩码后恒在 u64 范围")
.unwrap_or(u64::MAX)
}
/// `DataView.prototype.toString`:校验 receiver 后返回 `[object DataView]`。