-
Notifications
You must be signed in to change notification settings - Fork 202
Open
Description
I rewrite a project from c++ to golang.
Issue :
it use lua-socket in cpp and i use go-lua in go...
I want to know go-lua is or not support lua-socket??
C++ code:
static int base_open(lua_State *L) {
if (socket_open()) {
/* export functions (and leave namespace table on top of stack) */
lua_newtable(L);
luaL_setfuncs(L, func, 0);
#ifdef LUASOCKET_DEBUG
lua_pushstring(L, "_DEBUG");
lua_pushboolean(L, 1);
lua_rawset(L, -3);
#endif
/* make version string available to scripts */
lua_pushstring(L, "_VERSION");
lua_pushstring(L, LUASOCKET_VERSION);
lua_rawset(L, -3);
return 1;
} else {
lua_pushstring(L, "unable to initialize library");
lua_error(L);
return 0;
}
}
Metadata
Metadata
Assignees
Labels
No labels