00001 /* 00002 ** Lua tables (hash) 00003 ** See Copyright Notice in lua.h 00004 */ 00005 00006 #ifndef GRIM_LTABLE_H 00007 #define GRIM_LTABLE_H 00008 00009 #include "engines/grim/lua/lobject.h" 00010 00011 namespace Grim { 00012 00013 #define node(t, i) (&(t)->node[i]) 00014 #define ref(n) (&(n)->ref) 00015 #define val(n) (&(n)->val) 00016 #define nhash(t) ((t)->nhash) 00017 00018 Hash *luaH_new(int32 nhash); 00019 void luaH_free(Hash *frees); 00020 TObject *luaH_get(Hash *t, TObject *r); 00021 TObject *luaH_set(Hash *t, TObject *r); 00022 Node *luaH_next(TObject *o, TObject *r); 00023 Node *hashnodecreate(int32 nhash); 00024 int32 present(Hash *t, TObject *key); 00025 00026 } // end of namespace Grim 00027 00028 #endif