lm_message_handler.c
changeset 12 63f06a23c235
parent 11 a8c6460d612b
child 16 09b375e9ce32
equal deleted inserted replaced
11:a8c6460d612b 12:63f06a23c235
   111 }
   111 }
   112 
   112 
   113 static const luaL_Reg reg_f_lm_handler[] = {
   113 static const luaL_Reg reg_f_lm_handler[] = {
   114 	{ "new",   new_lm_handler       },
   114 	{ "new",   new_lm_handler       },
   115 	{ "bless", bless_lua_lm_handler },
   115 	{ "bless", bless_lua_lm_handler },
   116 	{ NULL,    NULL                          },
   116 	{ NULL,    NULL                 },
   117 };
   117 };
   118 
   118 
   119 static const luaL_Reg reg_m_lm_handler[] = {
   119 static const luaL_Reg reg_m_lm_handler[] = {
   120 	{ "invalidate", invalidate_lm_handler },
   120 	{ "invalidate", invalidate_lm_handler },
   121 	{ "valid",      valid_lm_handler      },
   121 	{ "valid",      valid_lm_handler      },
   122 	{ "pointer",    pointer_lm_handler    },
   122 	{ "pointer",    pointer_lm_handler    },
   123 	{ "__gc",       gc_lm_handler         },
   123 	{ "__gc",       gc_lm_handler         },
   124 	{ NULL,         NULL                           },
   124 	{ NULL,         NULL                  },
   125 };
   125 };
   126 
   126 
   127 int luaopen_lm_message_handler (lua_State *L)
   127 int luaopen_lm_message_handler (lua_State *L)
   128 {
   128 {
   129 	luaL_newmetatable (L, "loudmouth.message_handler");
   129 	luaL_newmetatable (L, "loudmouth.message_handler");