MCPcopy Create free account
hub / github.com/bloomberg/comdb2 / luaB_assert

Function luaB_assert

lua/lbaselib.c:342–347  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

340
341
342static int luaB_assert (lua_State *L) {
343 luaL_checkany(L, 1);
344 if (!lua_toboolean(L, 1))
345 return luaL_error(L, "%s", luaL_optstring(L, 2, "assertion failed!"));
346 return lua_gettop(L);
347}
348
349
350static int luaB_unpack (lua_State *L) {

Callers

nothing calls this directly

Calls 4

luaL_checkanyFunction · 0.85
lua_tobooleanFunction · 0.85
luaL_errorFunction · 0.85
lua_gettopFunction · 0.85

Tested by

no test coverage detected