lua-users home
lua-l archive

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

The Principle of Least Astonishment leads one to the position that type() ought not change in a way that is not backwardly compatible. One could make “newtype()” or, perhaps, have type() return two values (one of the existing values plus, optionally,  the __name field from the meta table)

That said, I do like the idea in principle & have done hacks similar to those described