[Date Prev][Date Next][Thread Prev][Thread Next]
[Date Index]
[Thread Index]
- Subject: Re: [PROPOSAL] a new function: table.proto()
- From: Luiz Henrique de Figueiredo <lhf@...>
- Date: Tue, 4 May 2010 08:07:43 -0300
> function table.proto (t)
> local tp = {}
> for k in pairs(t) do
> tp[k] = nil
> end
In principle, this loop has not effect because the table is empty and will
remain empty after the loop. In the current implementation it does have the
side effect that the keys are temporarily created in tp. Are you counting
on this behavior??