-
Notifications
You must be signed in to change notification settings - Fork 59
Closed
Labels
Description
On 2025-07-21 @prestwich wrote in 2973b98
“Merge pull request #490 from DaniPopes/no-alloc-fmt”:
MSRV-1.80): let as_slice = buf.as_flattened_mut();
fn new(limbs: [u64; LIMBS], mut base: u64) -> Self {
// We need to do this so we can guarantee that `buf` is big enough.
base = crate::utils::max_pow_u64(base);
let mut buf = [[MaybeUninit::uninit(); 2]; LIMBS];
// TODO(MSRV-1.80): let as_slice = buf.as_flattened_mut();
let as_slice = unsafe {
core::slice::from_raw_parts_mut(buf.as_mut_ptr().cast::<MaybeUninit<u64>>(), LIMBS * 2)
};
let mut init = 0;
for (i, limb) in SpigotLittle::new(limbs, base).enumerate() {