[Date Prev][Date Next][Thread Prev][Thread Next]
[Date Index]
[Thread Index]
- Subject: RE: tables holding nil
- From: Richter, Jörg <Joerg.Richter@...>
- Date: Thu, 23 Jul 2009 13:25:54 +0200
>> Couldn't the same reasoning be applied here, and change
>table lookups to
>> return nil if the table itself was nil? (But throw an error
>when setting)
>> This would mean that heightmap[x][y] would return nil
>instead of erroring,
>> and it would give somewhat more consistency.
>>
>
>Myself and several other people I know would do anything for this :)
How about:
debug.setmetatable( nil, { __index=function() end } )
print( NIL[nil] )
Jörg
- References:
- tables holding nil, Cosmin Apreutesei
- Re: tables holding nil, Jim Whitehead II
- Re: tables holding nil, Luiz Henrique de Figueiredo
- Re: tables holding nil, Cosmin Apreutesei
- Re: tables holding nil, Luiz Henrique de Figueiredo
- Re: tables holding nil, Cosmin Apreutesei
- Re: tables holding nil, Luiz Henrique de Figueiredo
- Re: tables holding nil, Kristofer Karlsson
- Re: tables holding nil, Luiz Henrique de Figueiredo
- Re: tables holding nil, Kristofer Karlsson
- Re: tables holding nil, Matthew Wild