[Date Prev][Date Next][Thread Prev][Thread Next]
[Date Index]
[Thread Index]
- Subject: Re: use of gettop to change functionality
- From: Patrick Donnelly <batrick@...>
- Date: Tue, 1 Mar 2011 15:21:30 -0500
On Tue, Mar 1, 2011 at 1:27 PM, Eduardo Ochs <eduardoochs@gmail.com> wrote:
> mytableinsert = function (T, ...)
> local objects = table.pack(...)
> for i=1,n do
> T.n = T.n + 1
> T[n] = objects[i]
> end
> return T
> end
I really hope programs like this do not become common. Making a new
garbage table on every insert?! This is why I advocated having
table.pack accept a table argument...
--
- Patrick Donnelly