new macros `ttis*'

This commit is contained in:
Roberto Ierusalimschy
2002-08-05 11:50:39 -03:00
parent 9fb80bde3c
commit 5037196f6f
6 changed files with 70 additions and 54 deletions

4
ltm.c
View File

@@ -1,5 +1,5 @@
/*
** $Id: ltm.c,v 1.97 2002/06/25 19:17:22 roberto Exp roberto $
** $Id: ltm.c,v 1.98 2002/07/17 16:25:13 roberto Exp $
** Tag methods
** See Copyright Notice in lua.h
*/
@@ -47,7 +47,7 @@ void luaT_init (lua_State *L) {
const TObject *luaT_gettm (Table *events, TMS event, TString *ename) {
const TObject *tm = luaH_getstr(events, ename);
lua_assert(event <= TM_MODE);
if (ttype(tm) == LUA_TNIL) { /* no tag method? */
if (ttisnil(tm)) { /* no tag method? */
events->flags |= (1u<<event); /* cache this fact */
return NULL;
}