aboutsummaryrefslogtreecommitdiff
path: root/lua.h
diff options
context:
space:
mode:
authorRoberto Ierusalimschy <roberto@inf.puc-rio.br>2003-11-05 09:59:14 -0200
committerRoberto Ierusalimschy <roberto@inf.puc-rio.br>2003-11-05 09:59:14 -0200
commitfa198197a0202bd3a7b68d228cd1c2fd88166ff7 (patch)
tree536f37e38fb5e80fa580c42f2d09d6e10410e075 /lua.h
parent1e944de6cb6a20f6abeaab6f5d1039d06d8d2812 (diff)
downloadlua-fa198197a0202bd3a7b68d228cd1c2fd88166ff7.tar.gz
lua-fa198197a0202bd3a7b68d228cd1c2fd88166ff7.tar.bz2
lua-fa198197a0202bd3a7b68d228cd1c2fd88166ff7.zip
lua_(set)getglobal are ok to use
Diffstat (limited to 'lua.h')
-rw-r--r--lua.h7
1 files changed, 4 insertions, 3 deletions
diff --git a/lua.h b/lua.h
index efd633c5..319d5d06 100644
--- a/lua.h
+++ b/lua.h
@@ -1,5 +1,5 @@
1/* 1/*
2** $Id: lua.h,v 1.183 2003/10/20 12:25:23 roberto Exp roberto $ 2** $Id: lua.h,v 1.184 2003/10/21 10:58:58 roberto Exp roberto $
3** Lua - An Extensible Extension Language 3** Lua - An Extensible Extension Language
4** Tecgraf: Computer Graphics Technology Group, PUC-Rio, Brazil 4** Tecgraf: Computer Graphics Technology Group, PUC-Rio, Brazil
5** http://www.lua.org mailto:info@lua.org 5** http://www.lua.org mailto:info@lua.org
@@ -277,6 +277,9 @@ LUA_API lua_Alloc lua_getallocf (lua_State *L, void **ud);
277#define lua_pushliteral(L, s) \ 277#define lua_pushliteral(L, s) \
278 lua_pushlstring(L, "" s, (sizeof(s)/sizeof(char))-1) 278 lua_pushlstring(L, "" s, (sizeof(s)/sizeof(char))-1)
279 279
280#define lua_setglobal(L,s) lua_setfield(L, LUA_GLOBALSINDEX, s)
281#define lua_getglobal(L,s) lua_getfield(L, LUA_GLOBALSINDEX, s)
282
280 283
281 284
282/* 285/*
@@ -286,8 +289,6 @@ LUA_API lua_Alloc lua_getallocf (lua_State *L, void **ud);
286#define lua_open() luaL_newstate() 289#define lua_open() luaL_newstate()
287 290
288#define lua_getregistry(L) lua_pushvalue(L, LUA_REGISTRYINDEX) 291#define lua_getregistry(L) lua_pushvalue(L, LUA_REGISTRYINDEX)
289#define lua_setglobal(L,s) lua_setfield(L, LUA_GLOBALSINDEX, s)
290#define lua_getglobal(L,s) lua_getfield(L, LUA_GLOBALSINDEX, s)
291 292
292 293
293/* compatibility with ref system */ 294/* compatibility with ref system */