MCPcopy Create free account
hub / github.com/ObEngine/ObEngine / getnumlimit

Function getnumlimit

extlibs/lua/src/lstrlib.c:1421–1427  ·  view source on GitHub ↗

** Read an integer numeral and raises an error if it is larger ** than the maximum size for integers. */

Source from the content-addressed store, hash-verified

1419** than the maximum size for integers.
1420*/
1421static int getnumlimit (Header *h, const char **fmt, int df) {
1422 int sz = getnum(fmt, df);
1423 if (sz > MAXINTSIZE || sz <= 0)
1424 return luaL_error(h->L, "integral size (%d) out of limits [1,%d]",
1425 sz, MAXINTSIZE);
1426 return sz;
1427}
1428
1429
1430/*

Callers 1

getoptionFunction · 0.85

Calls 2

getnumFunction · 0.85
luaL_errorFunction · 0.85

Tested by

no test coverage detected