MCPcopy Create free account
hub / github.com/Tencent/sluaunreal / lua_Number lua_tonumberx

Function lua_Number lua_tonumberx

Plugins/slua_unreal/External/lua/lapi.cpp:343–351  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

341
342
343LUA_API lua_Number lua_tonumberx (lua_State *L, int idx, int *pisnum) {
344 lua_Number n;
345 const TValue *o = index2addr(L, idx);
346 int isnum = tonumber(o, &n);
347 if (!isnum)
348 n = 0; /* call to 'tonumber' may change 'n' even if it fails */
349 if (pisnum) *pisnum = isnum;
350 return n;
351}
352
353
354LUA_API lua_Integer lua_tointegerx (lua_State *L, int idx, int *pisnum) {

Callers

nothing calls this directly

Calls 1

index2addrFunction · 0.85

Tested by

no test coverage detected