lua-users home
lua-l archive

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


On Thu, Dec 30, 2010 at 4:16 PM, Dirk Laurie <dpl@sun.ac.za> wrote:
> On Thu, Dec 30, 2010 at 10:25:22PM +0200, Greg Falcon wrote:
>>
>> Part of the point here is to support "holes".  You want
>>    array(nil, nil, nil)
>> to make a three-element array containing all nils.
> Your own post, fifteen minutes later, says that the real problem
> is that people can't accept that nil is not a first-class value,
> and that if one tried making it into that, the result would be
> very different from Lua.
>
> I agree with Greg II, not with Greg I.

This will be my last reply, because this thread is generating a crazy
amount of heat.  I should have stayed out of it entirely.  But if you
actually read my message in question, you would have seen:

"Lorenzo Donati got it exactly right -- if you want an
array-with-holes, build one out of tables and metamethods."

Here Mark Hamburg is proposing an API for an array-with-holes built
out of tables and metamethods.  I can't for the life of me figure out
why you think my discussing how it should support nil is in any way
inconsistent or contradictory.

Have fun,
Greg F