/// Returns `layout` or the minimum size/align layout for scudo if its too small.
Returns `layout` or the minimum size/align layout for scudo if its too small.
Returns ` layout ` or the minimum size / align layout for scudo if its too small .
fn fit_layout(layout: Layout) -> Layout {
    // SAFETY: SCUDO_MIN_ALIGN is constant and known to be powers of 2.
    let min_align = unsafe { SCUDO_MIN_ALIGN } as usize;
    let align = max(min_align, layout.align());
    // SAFETY: Size and align are good by construction.
    unsafe { Layout::from_size_align_unchecked(layout.size(), align) }
}
fn fit_layout ( layout : Layout ) -> Layout { // SAFETY: SCUDO_MIN_ALIGN is constant and known to be powers of 2. let min_align = unsafe { SCUDO_MIN_ALIGN } as usize ; let align = max ( min_align , layout . align ( ) ) ; // SAFETY: Size and align are good by construction. unsafe { Layout :: from_size_align_unchecked ( layout . size ( ) , align ) } }
Returns `layout` or the minimum size/align layout for scudo if its too small.
Returns ` layout ` or the minimum size / align layout for scudo if its too small .
layout
Layout