pub unsafe fn lua_tointeger(L: *mut lua_State, idx: c_int) -> lua_IntegerExpand description
Attempts to convert the value at the given index to an integer, and returns it.
This function operates in a similar way as lua_tonumber, but it has the
final result floored to an integer. While it will convert a string into a
number on the stack, it will not modify the stack value into an integer.