lua-users home
lua-l archive

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


On Tue, Jul 26, 2016 at 10:45 AM, Peter Melnichenko <mpeterval@gmail.com> wrote:
> Every `t[k] = v` assignment will soon cause an error if `k` happens to
> be one of metamethod names.

It's generally a bother writing wrappers around tables, because as
soon as you introduce some convenient helper methods, they will
collide with some arbitrary key that the user wants to store. pl.Map
suffers from this problem, which is why pl.Set has no methods. There
are fixes but they are expensive.

But, back to topic: currently, the rules are simple. Adding arbitrary
extra rules makes it harder to explain and use the language.