lua-users home
lua-l archive

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



On 16-07-18 07:53 AM, Dirk Laurie wrote:
> It has several times been noted on this list that you can have e.g.
> tbl.a.b.c.d.e evaluating to nil if any intermediate table does not exist,
> instead of raising an error, by
> 
>    debug.setmetatable(nil,{__index = load''})
> 
> Is there any subtle undesirable consequence to doing this?
> 
tbl.a.b.c.d.e = tbl.a.b.c.d.e or {}