lua-users home
lua-l archive

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


Hi,

Ron Bessems wrote:
> I've looked at chapter 13.4 (table access meta-methods) but it seems
> that those access methods cannot track if a variable already exists,
> so then a proxy table is used, but then we loose the ability to
> iterate over the table.

Yes, proxy tables are the recommended method. And since you
already control the globals -- what's keeping you from replacing
pairs and ipairs with your own functions? Bonus: you get notified
of iteration, too.

Bye,
     Mike