src/t_enc_crc.c
int
luaopen_t_enc_crc( lua_State *L )
{
	// just make metatable known to be able to register and check userdata
	// this is only avalable a <instance>:func()
	luaL_newmetatable( L, T_ENC_CRC_TYPE );   // stack: functions meta
	luaL_setfuncs( L, t_enc_crc_m, 0 );
	lua_setfield( L, -1, "__index" );

	// Push the class onto the stack
	// this is avalable as Crc.new
	luaL_newlib( L, t_enc_crc_cf );
	// set the constructor metatable Crc()
	luaL_newlib( L, t_enc_crc_fm );
	lua_setmetatable( L, -2 );
	return 1;
}
/**--------------------------------------------------------------------------
 * Pushes the T.Encode.CRC library onto the stack
 *          - creates Metatable with functions
 *          - creates metatable with methods
 * \param   L      The Lua state.
 * \lreturn table  the library
 * \return  int    # of values pushed onto the stack.
 * --------------------------------------------------------------------------*/
Pushes the T.Encode.CRC library onto the stack
- creates Metatable with functions
- creates metatable with methods
\param   L      The Lua state.
\lreturn table  the library
\return  int    # of values pushed onto the stack.
Pushes the T . Encode . CRC library onto the stack - creates Metatable with functions - creates metatable with methods \ param L The Lua state . \ lreturn table the library \ return int # of values pushed onto the stack .
int
luaopen_t_enc_crc( lua_State *L )
{
	luaL_newmetatable( L, T_ENC_CRC_TYPE );   
	luaL_setfuncs( L, t_enc_crc_m, 0 );
	lua_setfield( L, -1, "__index" );
	luaL_newlib( L, t_enc_crc_cf );
	luaL_newlib( L, t_enc_crc_fm );
	lua_setmetatable( L, -2 );
	return 1;
}
int luaopen_t_enc_crc ( lua_State * L ) { luaL_newmetatable ( L , T_ENC_CRC_TYPE ) ; luaL_setfuncs ( L , t_enc_crc_m , 0 ) ; lua_setfield ( L , -1 , " " ) ; luaL_newlib ( L , t_enc_crc_cf ) ; luaL_newlib ( L , t_enc_crc_fm ) ; lua_setmetatable ( L , -2 ) ; return 1 ; }
Pushes the T.Encode.CRC library onto the stack
          - creates Metatable with functions
          - creates metatable with methods
 \param   L      The Lua state.
Pushes the T . Encode . CRC library onto the stack - creates Metatable with functions - creates metatable with methods \ param L The Lua state .
// just make metatable known to be able to register and check userdata // this is only avalable a <instance>:func() // stack: functions meta // Push the class onto the stack // this is avalable as Crc.new // set the constructor metatable Crc()