util-src/*.c: Use the more concise lua_setfield

This commit is contained in:
Kim Alvefur 2014-09-17 02:23:17 +02:00
parent c57e98cd7d
commit 4f6f0fe480
4 changed files with 7 additions and 13 deletions

View file

@ -83,8 +83,7 @@ static const luaL_Reg Reg[] =
LUALIB_API int luaopen_util_windows(lua_State *L) {
lua_newtable(L);
luaL_register(L, NULL, Reg);
lua_pushliteral(L, "version"); /** version */
lua_pushliteral(L, "-3.14");
lua_settable(L,-3);
lua_setfield(L, -2, "version");
return 1;
}