MCPcopy Create free account
hub / github.com/EmmyLua/EmmyLuaDebugger / lua_tonumberx

Function lua_tonumberx

third-party/lua-5.4.6/src/lapi.c:379–386  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

377
378
379LUA_API lua_Number lua_tonumberx (lua_State *L, int idx, int *pisnum) {
380 lua_Number n = 0;
381 const TValue *o = index2value(L, idx);
382 int isnum = tonumber(o, &n);
383 if (pisnum)
384 *pisnum = isnum;
385 return n;
386}
387
388
389LUA_API lua_Integer lua_tointegerx (lua_State *L, int idx, int *pisnum) {

Callers 1

luaL_checknumberFunction · 0.70

Calls 1

index2valueFunction · 0.70

Tested by

no test coverage detected