diff options
Diffstat (limited to '')
| -rw-r--r-- | lua.h | 5 |
1 files changed, 3 insertions, 2 deletions
| @@ -2,7 +2,7 @@ | |||
| 2 | ** LUA - An Extensible Extension Language | 2 | ** LUA - An Extensible Extension Language |
| 3 | ** TeCGraf: Grupo de Tecnologia em Computacao Grafica, PUC-Rio, Brazil | 3 | ** TeCGraf: Grupo de Tecnologia em Computacao Grafica, PUC-Rio, Brazil |
| 4 | ** e-mail: lua@tecgraf.puc-rio.br | 4 | ** e-mail: lua@tecgraf.puc-rio.br |
| 5 | ** $Id: lua.h,v 4.3 1997/04/15 16:52:20 roberto Exp roberto $ | 5 | ** $Id: lua.h,v 4.4 1997/05/26 14:42:51 roberto Exp roberto $ |
| 6 | */ | 6 | */ |
| 7 | 7 | ||
| 8 | 8 | ||
| @@ -78,7 +78,6 @@ int lua_tag (lua_Object object); | |||
| 78 | 78 | ||
| 79 | int lua_ref (int lock); /* In: value */ | 79 | int lua_ref (int lock); /* In: value */ |
| 80 | lua_Object lua_getref (int ref); | 80 | lua_Object lua_getref (int ref); |
| 81 | void lua_pushref (int ref); | ||
| 82 | void lua_unref (int ref); | 81 | void lua_unref (int ref); |
| 83 | 82 | ||
| 84 | lua_Object lua_createtable (void); | 83 | lua_Object lua_createtable (void); |
| @@ -90,6 +89,8 @@ long lua_collectgarbage (long limit); | |||
| 90 | /* =============================================================== */ | 89 | /* =============================================================== */ |
| 91 | /* some useful macros */ | 90 | /* some useful macros */ |
| 92 | 91 | ||
| 92 | #define lua_pushref(ref) (lua_pushobject(lua_getref(ref))) | ||
| 93 | |||
| 93 | #define lua_refobject(o,l) (lua_pushobject(o), lua_ref(l)) | 94 | #define lua_refobject(o,l) (lua_pushobject(o), lua_ref(l)) |
| 94 | 95 | ||
| 95 | #define lua_register(n,f) (lua_pushcfunction(f), lua_setglobal(n)) | 96 | #define lua_register(n,f) (lua_pushcfunction(f), lua_setglobal(n)) |
