cppcheck/cfg/lua.cfg

157 lines
4.9 KiB
INI
Raw Normal View History

<?xml version="1.0"?>
<def format="2">
<!-- Lua C API. See https://www.lua.org/manual/5.3/manual.html#4 -->
<!-- The Lua C API is typically include by '#include <lua.h>' or '#include "lua.h"' -->
<!-- ########## Lua C API Types ########## -->
<!-- https://www.lua.org/manual/5.3/manual.html#lua_Number -->
<define name="lua_Number" value="double"/>
<!-- https://www.lua.org/manual/5.3/manual.html#lua_Integer -->
<podtype name="lua_Integer" sign="s"/>
<!-- https://www.lua.org/manual/5.3/manual.html#lua_Unsigned -->
<podtype name="lua_Unsigned" sign="u"/>
<!-- ########## Lua C API Functions ########## -->
<!-- int lua_error (lua_State *L); -->
<function name="lua_error">
<noreturn>true</noreturn>
<returnValue type="int"/>
<arg nr="1"/>
</function>
<!-- int lua_gettop (lua_State *L); -->
<function name="lua_gettop">
<noreturn>false</noreturn>
<returnValue type="int"/>
<use-retval/>
<arg nr="1"/>
</function>
<!-- int lua_isboolean (lua_State *L, int index); -->
<!-- int lua_iscfunction (lua_State *L, int index); -->
<!-- int lua_isfunction (lua_State *L, int index); -->
<!-- int lua_isinteger (lua_State *L, int index); -->
<!-- int lua_islightuserdata (lua_State *L, int index); -->
<!-- int lua_isnil (lua_State *L, int index); -->
<!-- int lua_isnone (lua_State *L, int index); -->
<!-- int lua_isnoneornil (lua_State *L, int index); -->
<!-- int lua_isnumber (lua_State *L, int index); -->
<!-- int lua_isstring (lua_State *L, int index); -->
<!-- int lua_istable (lua_State *L, int index); -->
<!-- int lua_isthread (lua_State *L, int index); -->
<!-- int lua_isuserdata (lua_State *L, int index); -->
<function name="lua_isboolean,lua_iscfunction,lua_isfunction,lua_isinteger,lua_islightuserdata,lua_isnil,lua_isnone,lua_isnoneornil,lua_isnumber,lua_isstring,lua_istable,lua_isthread,lua_isuserdata">
<noreturn>false</noreturn>
<returnValue type="int"/>
<use-retval/>
<arg nr="1"/>
<arg nr="2" direction="in">
<not-uninit/>
<not-bool/>
</arg>
</function>
<!-- int lua_isyieldable (lua_State *L); -->
<function name="lua_isyieldable">
<noreturn>false</noreturn>
<returnValue type="int"/>
<use-retval/>
<arg nr="1"/>
</function>
<!-- lua_State *lua_newstate (lua_Alloc f, void *ud); -->
<function name="lua_newstate">
<noreturn>false</noreturn>
<returnValue type="lua_State *"/>
<use-retval/>
<arg nr="1"/>
<arg nr="2"/>
</function>
<!-- void lua_pop (lua_State *L, int n); -->
<function name="lua_pop">
<noreturn>false</noreturn>
<returnValue type="void"/>
<arg nr="1"/>
<arg nr="2" direction="in">
<not-uninit/>
<valid>1:</valid>
</arg>
</function>
<!-- void lua_pushnil (lua_State *L); -->
<function name="lua_pushnil">
<noreturn>false</noreturn>
<returnValue type="void"/>
<arg nr="1"/>
</function>
<!-- void lua_pushnumber (lua_State *L, lua_Number n); -->
<function name="lua_pushnumber">
<noreturn>false</noreturn>
<returnValue type="void"/>
<arg nr="1"/>
<arg nr="2" direction="in">
<not-uninit/>
</arg>
</function>
<!-- void lua_pushvalue (lua_State *L, int index); -->
<function name="lua_pushvalue">
<noreturn>false</noreturn>
<returnValue type="void"/>
<arg nr="1"/>
<arg nr="2" direction="in">
<not-uninit/>
</arg>
</function>
<!-- const char *lua_tolstring (lua_State *L, int index, size_t *len); -->
<function name="lua_tolstring">
<noreturn>false</noreturn>
<returnValue type="const char *"/>
<arg nr="1"/>
<arg nr="2" direction="in">
<not-uninit/>
</arg>
<arg nr="3" direction="out">
<not-bool/>
</arg>
</function>
<!-- lua_Number lua_tonumber (lua_State *L, int index); -->
<function name="lua_tonumber">
<noreturn>false</noreturn>
<returnValue type="lua_Number"/>
<use-retval/>
<arg nr="1"/>
<arg nr="2" direction="in">
<not-uninit/>
<not-bool/>
</arg>
</function>
<!-- lua_Number lua_tonumberx (lua_State *L, int index, int *isnum); -->
<function name="lua_tonumberx">
<noreturn>false</noreturn>
<returnValue type="lua_Number"/>
<arg nr="1"/>
<arg nr="2" direction="in">
<not-uninit/>
</arg>
<arg nr="3" direction="out">
<not-bool/>
</arg>
</function>
<!-- const char *lua_tostring (lua_State *L, int index); -->
<function name="lua_tostring">
<noreturn>false</noreturn>
<returnValue type="const char *"/>
<use-retval/>
<arg nr="1"/>
<arg nr="2" direction="in">
<not-uninit/>
<not-bool/>
</arg>
</function>
<!-- int luaL_error (lua_State *L, const char *fmt, ...); -->
<function name="luaL_error">
<noreturn>true</noreturn>
<returnValue type="int"/>
<arg nr="1"/>
<arg nr="2" direction="in">
<not-uninit/>
</arg>
<arg nr="variadic" direction="in">
<not-uninit/>
</arg>
</function>
</def>