Skip to main content

MAX_ARRAY_INDEX

Constant MAX_ARRAY_INDEX 

Source
pub const MAX_ARRAY_INDEX: usize = _ /* 1_048_575usize */;
Expand description

The largest index a bare numeric segment names on an array. A larger number is a key, so no path can make a write pad an array past it: a trace read from outside the engine, or a computed path, could otherwise name data.list.4294967295 and have a write allocate for every slot before it, which overflows on wasm32 and exhausts memory anywhere.