[Date Prev][Date Next][Thread Prev][Thread Next]
[Date Index]
[Thread Index]
- Subject: Re: passing vararg to xpcall?
- From: PA <petite.abeille@...>
- Date: Thu, 23 Feb 2006 19:54:17 +0100
On Feb 23, 2006, at 19:28, PA wrote:
Is there a way to get all the return values, including the ones after
a nil?
Answering my own question:
function test()
return 1, nil, 2, nil, 3
end
local someResults = { test() }
print( unpack( someResults, 1, table.maxn( someResults ) ) )
> 1 nil 2 nil 3
Cheers
--
PA, Onnay Equitursay
http://alt.textdrive.com/