no more 'ccall' nor 'cpcall' functions. (With light C functions they
are obsolete.)
This commit is contained in:
13
lauxlib.c
13
lauxlib.c
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
** $Id: lauxlib.c,v 1.206 2010/03/29 17:44:31 roberto Exp roberto $
|
||||
** $Id: lauxlib.c,v 1.207 2010/04/09 16:14:46 roberto Exp roberto $
|
||||
** Auxiliary functions for building Lua libraries
|
||||
** See Copyright Notice in lua.h
|
||||
*/
|
||||
@@ -766,14 +766,3 @@ LUALIB_API void luaL_checkversion_ (lua_State *L, lua_Number ver) {
|
||||
ver, *v);
|
||||
}
|
||||
|
||||
|
||||
LUALIB_API int luaL_cpcall (lua_State *L, lua_CFunction f, int nargs,
|
||||
int nresults) {
|
||||
nargs++; /* to include function itself */
|
||||
lua_rawgeti(L, LUA_REGISTRYINDEX, LUA_RIDX_CCALL);
|
||||
lua_insert(L, -nargs); /* 'ccall' is real function to be called */
|
||||
lua_pushlightuserdata(L, &f);
|
||||
lua_insert(L, -nargs); /* 'f' address is its first argument */
|
||||
return lua_pcall(L, nargs, nresults, 0);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user