From 32089106fa10eba08e946693cb2939a4ab293f77 Mon Sep 17 00:00:00 2001 From: Alexander Lantsev Date: Mon, 4 Apr 2016 09:44:12 +0000 Subject: MirLua: - no need to copy pointer data in MT - project cleanup - version bump git-svn-id: http://svn.miranda-ng.org/main/trunk@16584 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c --- plugins/MirLua/src/mlua_utils.cpp | 20 ++------------------ 1 file changed, 2 insertions(+), 18 deletions(-) (limited to 'plugins/MirLua/src/mlua_utils.cpp') diff --git a/plugins/MirLua/src/mlua_utils.cpp b/plugins/MirLua/src/mlua_utils.cpp index 7bd46d4db2..7d4515bede 100644 --- a/plugins/MirLua/src/mlua_utils.cpp +++ b/plugins/MirLua/src/mlua_utils.cpp @@ -90,7 +90,7 @@ int luaM_print(lua_State *L) int luaM_toansi(lua_State *L) { - const char* value = luaL_checkstring(L, 1); + const char *value = luaL_checkstring(L, 1); int codepage = luaL_optinteger(L, 2, Langpack_GetDefaultCodePage()); ptrA string(mir_strdup(value)); @@ -101,7 +101,7 @@ int luaM_toansi(lua_State *L) int luaM_toucs2(lua_State *L) { - const char* value = luaL_checkstring(L, 1); + const char *value = luaL_checkstring(L, 1); ptrW unicode(mir_utf8decodeW(value)); size_t length = mir_wstrlen(unicode) * sizeof(wchar_t); @@ -121,22 +121,6 @@ bool luaM_toboolean(lua_State *L, int idx) return lua_toboolean(L, idx) > 0; } -int luaM_totable(lua_State *L) -{ - const char *tname = luaL_checkstring(L, 2); - - char message[256]; - mir_snprintf(message, "Use %s(...) instead", tname); - ObsoleteMethod(L, message); - - luaL_getmetatable(L, tname); - lua_getfield(L, -1, "__call"); - lua_pushvalue(L, 1); - luaM_pcall(L, 1, 1); - - return 1; -} - int luaM_ptr2number(lua_State *L) { luaL_checktype(L, 1, LUA_TLIGHTUSERDATA); -- cgit v1.2.3