| LUA_TYPE(3) | Library Functions Manual | LUA_TYPE(3) |
lua_type — returns
the type of the value, function indicator [-0, +0, -]
#include
<lua.h>
int
lua_type(lua_State
*L, int index);
lua_type()
returns the type of the value in the given acceptable index, or
LUA_TNONE for a non-valid index (that is, an index
to an "empty" stack position). The types returned by
lua_type are coded by the following constants
defined in <lua.h>:
LUA_TNIL, LUA_TNUMBER,
LUA_TBOOLEAN, LUA_TSTRING,
LUA_TTABLE, LUA_TFUNCTION,
LUA_TUSERDATA, LUA_TTHREAD,
and LUA_TLIGHTUSERDATA.
Roberto Ierusalimschy, Luiz Henrique de Figueiredo, and Waldemar Celes, Lua 5.1 Reference Manual.
The lua_type() manual page is based on Lua
Reference Manual 5.1 and was created by Sergey Bronnikov.
| July 18, 2022 | Debian |