MCPcopy Create free account
hub / github.com/RomanKubiak/ctrlr / lua_tointeger

Function lua_tointeger

Source/Misc/lua/src/lua.c:2172–2183  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

2170
2171
2172LUA_API lua_Integer lua_tointeger (lua_State *L, int idx) {
2173TValue n;
2174const TValue *o = index2adr(L, idx);
2175if (tonumber(o, &n)) {
2176lua_Integer res;
2177lua_Number num = nvalue(o);
2178lua_number2integer(res, num);
2179return res;
2180}
2181else
2182return 0;
2183}
2184
2185
2186LUA_API int lua_toboolean (lua_State *L, int idx) {

Callers 11

alter_use_countMethod · 0.85
is_state_unreferencedMethod · 0.85
do_fromMethod · 0.85
luaL_checkintegerFunction · 0.85
checkintFunction · 0.85
luaL_refFunction · 0.85
db_getinfoFunction · 0.85
db_errorfbFunction · 0.85
g_readFunction · 0.85
getfieldFunction · 0.85
gmatch_auxFunction · 0.85

Calls 1

index2adrFunction · 0.85

Tested by

no test coverage detected