summaryrefslogtreecommitdiff
path: root/ltm.c
diff options
context:
space:
mode:
authorRoberto Ierusalimschy <roberto@inf.puc-rio.br>2001-03-02 14:27:50 -0300
committerRoberto Ierusalimschy <roberto@inf.puc-rio.br>2001-03-02 14:27:50 -0300
commit7b84f9e65c39542d16dc2b24bdfe5c07496f2042 (patch)
treea2f17d3ee9d40155bb12dbc096aa16a6414641fd /ltm.c
parent1e40b4dc615b7838305ea738bdd8e069adc0180f (diff)
downloadlua-7b84f9e65c39542d16dc2b24bdfe5c07496f2042.tar.gz
lua-7b84f9e65c39542d16dc2b24bdfe5c07496f2042.tar.bz2
lua-7b84f9e65c39542d16dc2b24bdfe5c07496f2042.zip
lower-case for macros with arguments
Diffstat (limited to 'ltm.c')
-rw-r--r--ltm.c14
1 files changed, 7 insertions, 7 deletions
diff --git a/ltm.c b/ltm.c
index aff4a227..df30955b 100644
--- a/ltm.c
+++ b/ltm.c
@@ -1,5 +1,5 @@
1/* 1/*
2** $Id: ltm.c,v 1.68 2001/02/22 18:59:59 roberto Exp roberto $ 2** $Id: ltm.c,v 1.69 2001/02/23 17:17:25 roberto Exp roberto $
3** Tag methods 3** Tag methods
4** See Copyright Notice in lua.h 4** See Copyright Notice in lua.h
5*/ 5*/
@@ -111,14 +111,14 @@ static void checktag (lua_State *L, int tag) {
111 111
112LUA_API int lua_copytagmethods (lua_State *L, int tagto, int tagfrom) { 112LUA_API int lua_copytagmethods (lua_State *L, int tagto, int tagfrom) {
113 int e; 113 int e;
114 LUA_LOCK(L); 114 lua_lock(L);
115 checktag(L, tagto); 115 checktag(L, tagto);
116 checktag(L, tagfrom); 116 checktag(L, tagfrom);
117 for (e=0; e<TM_N; e++) { 117 for (e=0; e<TM_N; e++) {
118 if (luaT_validevent(tagto, e)) 118 if (luaT_validevent(tagto, e))
119 luaT_gettm(G(L), tagto, e) = luaT_gettm(G(L), tagfrom, e); 119 luaT_gettm(G(L), tagto, e) = luaT_gettm(G(L), tagfrom, e);
120 } 120 }
121 LUA_UNLOCK(L); 121 lua_unlock(L);
122 return tagto; 122 return tagto;
123} 123}
124 124
@@ -156,7 +156,7 @@ const l_char *luaT_typename (global_State *G, const TObject *o) {
156 156
157LUA_API void lua_gettagmethod (lua_State *L, int t, const l_char *event) { 157LUA_API void lua_gettagmethod (lua_State *L, int t, const l_char *event) {
158 int e; 158 int e;
159 LUA_LOCK(L); 159 lua_lock(L);
160 e = luaI_checkevent(L, event, t); 160 e = luaI_checkevent(L, event, t);
161 checktag(L, t); 161 checktag(L, t);
162 if (luaT_validevent(t, e) && luaT_gettm(G(L), t, e)) { 162 if (luaT_validevent(t, e) && luaT_gettm(G(L), t, e)) {
@@ -165,13 +165,13 @@ LUA_API void lua_gettagmethod (lua_State *L, int t, const l_char *event) {
165 else 165 else
166 setnilvalue(L->top); 166 setnilvalue(L->top);
167 incr_top; 167 incr_top;
168 LUA_UNLOCK(L); 168 lua_unlock(L);
169} 169}
170 170
171 171
172LUA_API void lua_settagmethod (lua_State *L, int t, const l_char *event) { 172LUA_API void lua_settagmethod (lua_State *L, int t, const l_char *event) {
173 int e; 173 int e;
174 LUA_LOCK(L); 174 lua_lock(L);
175 e = luaI_checkevent(L, event, t); 175 e = luaI_checkevent(L, event, t);
176 checktag(L, t); 176 checktag(L, t);
177 if (!luaT_validevent(t, e)) 177 if (!luaT_validevent(t, e))
@@ -190,6 +190,6 @@ LUA_API void lua_settagmethod (lua_State *L, int t, const l_char *event) {
190 luaD_error(L, l_s("tag method must be a function (or nil)")); 190 luaD_error(L, l_s("tag method must be a function (or nil)"));
191 } 191 }
192 L->top--; 192 L->top--;
193 LUA_UNLOCK(L); 193 lua_unlock(L);
194} 194}
195 195