lib: remove array_chunks nightly feature

Removes the nightly `array_chunks` feature, since it is marked as
unlikely to be merged.

Usage is trivially refactored using iterators.
This commit is contained in:
elle
2025-09-08 17:08:22 +00:00
parent e291a2527a
commit bd13557f98
3 changed files with 4 additions and 7 deletions
-1
View File
@@ -1,7 +1,6 @@
#![no_std]
#![feature(
asm_const,
array_chunks,
core_intrinsics,
int_roundings,
let_chains,
+4 -5
View File
@@ -715,11 +715,10 @@ pub fn create_set_addr_space_buf(
ip: usize,
sp: usize,
) -> [u8; size_of::<usize>() * 3] {
let mut buf = [0_u8; 3 * size_of::<usize>()];
let mut chunks = buf.array_chunks_mut::<{ size_of::<usize>() }>();
*chunks.next().unwrap() = usize::to_ne_bytes(space);
*chunks.next().unwrap() = usize::to_ne_bytes(sp);
*chunks.next().unwrap() = usize::to_ne_bytes(ip);
let mut buf = [0u8; size_of::<usize>() * 3];
buf.copy_from_slice([space, sp, ip].map(usize::to_ne_bytes).as_flattened());
buf
}
-1
View File
@@ -13,7 +13,6 @@
#![allow(unused_variables)]
#![feature(alloc_error_handler)]
#![feature(allocator_api)]
#![feature(array_chunks)]
#![feature(asm_const)]
#![feature(c_variadic)]
#![feature(core_intrinsics)]