From ca318b560a225539e30e4b4fc5daeb5477ac638a Mon Sep 17 00:00:00 2001
From: Alexander M Pickering By default, Lua4Win will install packages in a user-local location, at Lua4Win's luarocks configuration lives at All of Lua4Win's binary packages are built using mingw64. If you intend to build your own modules they must be built with mingw64 if you want them to interoperate with Lua4Win-distributed Lua. Some of Lua4Win's packages needed patching or modification, source code is generally mirrored at git.lua4.win, and packaging code is kept separate- usually in a $ luarocks install tl
local function keys
+local function keys<K,V>(xs: {K:V}):{K}
local ks = {}
- for k, v in pairs(xs) do
+ for k, _ in pairs(xs) do
table.insert(ks, k)
end
return ks
end
-local s: {number:string} = keys({ a = 1, b = 2 })
+local s: {integer:string} = keys({ a = 1, b = 2 })
print(table.concat(s))
%APPDATA%/luarocks
. You can instead choose to install system-wide packages for all users with the --tree system
flag, these packages will be located at [INSTALLDIR]/luarocks
. You may need to be running as an administrator to install to this location.[INSTALLDIR]/config/config-5.1.lua
, and is a regular Lua file you can modify.
repo.*-packaging
Some of Lua4Win's packages needed patching or modification, source code is generally mirrored at git.lua4.win, and packaging code is kept separate- usually in a *-packaging
repo.