summaryrefslogtreecommitdiff
path: root/ltm.c
diff options
context:
space:
mode:
Diffstat (limited to 'ltm.c')
-rw-r--r--ltm.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/ltm.c b/ltm.c
index 06408307..3f400d4b 100644
--- a/ltm.c
+++ b/ltm.c
@@ -1,5 +1,5 @@
1/* 1/*
2** $Id: ltm.c,v 2.34 2015/03/30 15:42:27 roberto Exp roberto $ 2** $Id: ltm.c,v 2.35 2015/11/02 18:48:07 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*/
@@ -57,7 +57,7 @@ void luaT_init (lua_State *L) {
57** tag methods 57** tag methods
58*/ 58*/
59const TValue *luaT_gettm (Table *events, TMS event, TString *ename) { 59const TValue *luaT_gettm (Table *events, TMS event, TString *ename) {
60 const TValue *tm = luaH_getstr(events, ename); 60 const TValue *tm = luaH_getshortstr(events, ename);
61 lua_assert(event <= TM_EQ); 61 lua_assert(event <= TM_EQ);
62 if (ttisnil(tm)) { /* no tag method? */ 62 if (ttisnil(tm)) { /* no tag method? */
63 events->flags |= cast_byte(1u<<event); /* cache this fact */ 63 events->flags |= cast_byte(1u<<event); /* cache this fact */
@@ -79,7 +79,7 @@ const TValue *luaT_gettmbyobj (lua_State *L, const TValue *o, TMS event) {
79 default: 79 default:
80 mt = G(L)->mt[ttnov(o)]; 80 mt = G(L)->mt[ttnov(o)];
81 } 81 }
82 return (mt ? luaH_getstr(mt, G(L)->tmname[event]) : luaO_nilobject); 82 return (mt ? luaH_getshortstr(mt, G(L)->tmname[event]) : luaO_nilobject);
83} 83}
84 84
85 85