From afdb19ac82bcb7ceabd010a484505105977352ba Mon Sep 17 00:00:00 2001 From: Roberto Ierusalimschy <roberto@inf.puc-rio.br> Date: Wed, 14 Apr 2010 12:14:21 -0300 Subject: no more 'ccall' nor 'cpcall' functions. (With light C functions they are obsolete.) --- lauxlib.c | 13 +------------ 1 file changed, 1 insertion(+), 12 deletions(-) (limited to 'lauxlib.c') diff --git a/lauxlib.c b/lauxlib.c index d255f814..eebdaedd 100644 --- a/lauxlib.c +++ b/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); -} - -- cgit v1.2.3-55-g6feb