Skip to main content

positive_index_value

Function positive_index_value 

Source
pub fn positive_index_value(state: &LuaState, idx: i32) -> LuaValue
Expand description

Fast path for ordinary positive stack indices.

Stdlib C callbacks receive their arguments at positive indices. For hot callbacks such as ipairsaux, this avoids the negative/pseudo-index branches in index_to_value while preserving the same “missing argument is nil” behavior for positive indices.