lua-users home
lua-l archive

[Date Prev][Date Next][Thread Prev][Thread Next] [Date Index] [Thread Index]


On Mon, 13 Dec 2010 15:34:02 +0200, Enrico Colombini <erix@erix.it> wrote:

I wholeheartedly agree with Luiz here: "the array part is just an implementation detail". We should approach from the user's side first and look at internal implications later (if ever).

From the user's side bigger inconsistency is not the #t, which
is very well defined, and _behaves exactly as defined_.
in my opinion, it's this:

print(table.concat{"a","b","c","d", nil, "e"})
./lua: test.lua:1: invalid value (nil) at index 5 in table for 'concat'

Now, manual explicitly states that table value cannot be 'nil'.
Similar gotchas with tables created from return values,
while running ipairs on such tables etc..