I have a function (that I cannot change) returning multiple values :
function f1()
...
return a, b
end
and another function (that I cannot change) taking multiple arguments :
function f2(x, y, z)
...
end
is there a way to do :
f2(f1(), c)
and have x be a, y be b and z be c ?
You can't do it in one line because f2(f1(),c)
adjusts the results returned by f1
to a single value.
You could use intermediate results
local a, b = f1()
f2(a, b, c)
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With