pub const STACK_SIZE: usize = {
    #[cfg(debug_assertions)]
    {
        16 << 20 // 16MiB
    }
    #[cfg(not(debug_assertions))]
    {
        2 << 20 // 2 MiB
    }
}; // 16_777_216usize
Available on crate feature stack only.
Expand description

The size of any freshly allocated stacks. It was chosen to match the default stack size for threads in Rust.

The default stack size is larger in debug builds to correspond to the the larger STACK_RED_ZONE.