MAX_CAPTURES

Constant MAX_CAPTURES 

Source
pub const MAX_CAPTURES: usize = 1024;
Expand description

Maximum number of captured values allowed in a closure environment. This prevents unbounded memory allocation and potential resource exhaustion.