diff options
author | Roberto Ierusalimschy <roberto@inf.puc-rio.br> | 1997-12-11 15:21:11 -0200 |
---|---|---|
committer | Roberto Ierusalimschy <roberto@inf.puc-rio.br> | 1997-12-11 15:21:11 -0200 |
commit | 4daae2165d617e57ad1460471f8d902d38abac6e (patch) | |
tree | 84eb55fa794a864ac48b528a617d5293502190ea /lbuiltin.c | |
parent | cdd261f332c112b86eddd7438b9a06e1231e3e4c (diff) | |
download | lua-4daae2165d617e57ad1460471f8d902d38abac6e.tar.gz lua-4daae2165d617e57ad1460471f8d902d38abac6e.tar.bz2 lua-4daae2165d617e57ad1460471f8d902d38abac6e.zip |
new API function and built-in "lua_copytagmethods"
Diffstat (limited to 'lbuiltin.c')
-rw-r--r-- | lbuiltin.c | 10 |
1 files changed, 9 insertions, 1 deletions
@@ -1,5 +1,5 @@ | |||
1 | /* | 1 | /* |
2 | ** $Id: lbuiltin.c,v 1.14 1997/12/01 20:30:44 roberto Exp roberto $ | 2 | ** $Id: lbuiltin.c,v 1.15 1997/12/09 13:35:19 roberto Exp roberto $ |
3 | ** Built-in functions | 3 | ** Built-in functions |
4 | ** See Copyright Notice in lua.h | 4 | ** See Copyright Notice in lua.h |
5 | */ | 5 | */ |
@@ -299,6 +299,13 @@ static void newtag (void) | |||
299 | } | 299 | } |
300 | 300 | ||
301 | 301 | ||
302 | static void copytagmethods (void) | ||
303 | { | ||
304 | lua_pushnumber(lua_copytagmethods(luaL_check_number(1), | ||
305 | luaL_check_number(2))); | ||
306 | } | ||
307 | |||
308 | |||
302 | static void rawgettable (void) | 309 | static void rawgettable (void) |
303 | { | 310 | { |
304 | lua_Object t = luaL_nonnullarg(1); | 311 | lua_Object t = luaL_nonnullarg(1); |
@@ -431,6 +438,7 @@ static struct luaL_reg int_funcs[] = { | |||
431 | {"call", luaI_call}, | 438 | {"call", luaI_call}, |
432 | {"collectgarbage", luaI_collectgarbage}, | 439 | {"collectgarbage", luaI_collectgarbage}, |
433 | {"dofile", internaldofile}, | 440 | {"dofile", internaldofile}, |
441 | {"copytagmethods", copytagmethods}, | ||
434 | {"dostring", internaldostring}, | 442 | {"dostring", internaldostring}, |
435 | {"error", luaI_error}, | 443 | {"error", luaI_error}, |
436 | {"foreach", foreach}, | 444 | {"foreach", foreach}, |