use std::mem;
pub use plan::Plan;
use crate::{alloc, base::num::bounded, depot::map};
pub mod errors;
pub mod runtime;
pub(in crate::depot) use cores::Core;
pub(in crate::depot) use entries::{Bucket, Meta};
pub use slot::Vacant;
mod cores;
mod entries;
mod plan;
mod slot;
type Fields<T> = alloc::raw::Tail<
alloc::raw::Tail<
alloc::raw::Tail<
<map::raw::Layout<bounded::U32<0, { u32::MAX - 1 }>> as alloc::raw::Recipe>::Fields,
Meta,
>,
bounded::U32<0, { u32::MAX - 1 }>,
>,
mem::MaybeUninit<T>,
>;
impl<T, Tag> Core<T, Tag> {
fn recipe(
table: map::raw::Layout<bounded::U32<0, { u32::MAX - 1 }>>,
) -> impl alloc::raw::Recipe<Fields = Fields<T>> {
use alloc::raw::Recipe as _;
let capacity = table.shape().capacity().get();
alloc::raw::Recipe::tail::<Meta>(table, capacity)
.tail::<bounded::U32<0, { u32::MAX - 1 }>>(capacity)
.tail::<mem::MaybeUninit<T>>(capacity)
}
}