vim: rename extend(...) -> concat(...)
This commit is contained in:
parent
e9ccd1ec77
commit
0d3e8b878a
1 changed files with 2 additions and 2 deletions
|
@ -15,7 +15,7 @@ end
|
|||
-- extend({'a', 'b'}, {'c', 'd'}) == {'a', 'b', 'c', 'd'}
|
||||
-- extend({1, 2}, {3, 4}, {5, 6}) == {1, 2, 3, 4, 5, 6}
|
||||
--
|
||||
M.extend = function(...)
|
||||
M.concat = function(...)
|
||||
local result = {}
|
||||
for _, tbl in ipairs {...} do
|
||||
for _, v in pairs(tbl) do
|
||||
|
@ -33,7 +33,7 @@ end
|
|||
M.partial = function(f, ...)
|
||||
local argv = {...}
|
||||
return function(...)
|
||||
return f(unpack(M.extend(argv, {...})))
|
||||
return f(unpack(M.concat(argv, {...})))
|
||||
end
|
||||
end
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue