mirror of
https://github.com/appgurueu/modlib.git
synced 2024-11-25 16:53:46 +01:00
Add func.curry_full
This commit is contained in:
parent
7f05c5d07e
commit
eb2db70201
5
func.lua
5
func.lua
@ -17,6 +17,11 @@ function curry_tail(func, ...)
|
|||||||
return function(...) return func(unpack(modlib.table.concat({...}, args))) end
|
return function(...) return func(unpack(modlib.table.concat({...}, args))) end
|
||||||
end
|
end
|
||||||
|
|
||||||
|
function curry_full(func, ...)
|
||||||
|
local args = { ... }
|
||||||
|
return function() return func(unpack(args)) end
|
||||||
|
end
|
||||||
|
|
||||||
function args(...)
|
function args(...)
|
||||||
local args = { ... }
|
local args = { ... }
|
||||||
return function(func) return func(unpack(args)) end
|
return function(func) return func(unpack(args)) end
|
||||||
|
Loading…
Reference in New Issue
Block a user